//修正するボタン
function backPage(elem,url){
	elem.action=url;
	elem.submit();
}
function MovePage(elem,url){
	elem.action=url;
}
//画像切り替え
function swImg(iName,str)
{
	document.images[iName].src = str;
}

//ページ移動ボタン
function jumpPage( url ){
	document.location = url;
}


function flash_write( arg )
{
	var parm = []

  for( i = 0 ; i < arguments.length ; i++ )
  {
    parm[i] = arguments[i].split(' ').join('').split('=')
    
    switch (parm[i][0])
    {
      case '_swf'     : var _swf     = parm[i][1] ; break ;
      case '_quality' : var _quality = parm[i][1] ; break ;
      case '_loop'    : var _loop    = parm[i][1] ; break ;
      case '_bgcolor' : var _bgcolor = parm[i][1] ; break ;
      case '_wmode'   : var _wmode   = parm[i][1] ; break ;
      case '_play'    : var _play    = parm[i][1] ; break ;
      case '_menu'    : var _menu    = parm[i][1] ; break ;
      case '_scale'   : var _scale   = parm[i][1] ; break ;
      case '_salign'  : var _salign  = parm[i][1] ; break ;
      case '_height'  : var _height  = parm[i][1] ; break ;
      case '_width'   : var _width   = parm[i][1] ; break ;
      case '_hspace'  : var _hspace  = parm[i][1] ; break ;
      case '_vspace'  : var _vspace  = parm[i][1] ; break ;
      case '_align'   : var _align   = parm[i][1] ; break ;
      case '_class'   : var _class   = parm[i][1] ; break ;
      case '_id'      : var _id      = parm[i][1] ; break ;
      case '_name'    : var _name    = parm[i][1] ; break ;
      case '_style'   : var _style   = parm[i][1] ; break ;
      case '_declare' : var _declare = parm[i][1] ; break ;
      default        :;
    }
  }
  
  var htm = ""
  
                    
  htm+="<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='https://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0' width='" + _width + "' height='" + _height + "'>"

  if(!!_swf)     htm+="<param  name     = 'movie'   value ='" + _swf     + "'>"
  if(!!_quality) htm+="<param  name     = 'quality' value ='" + _quality + "'>"
  if(!!_loop)    htm+="<param  name     = 'loop'    value ='" + _loop    + "'>"
  if(!!_bgcolor) htm+="<param  name     = 'bgcolor' value ='" + _bgcolor + "'>"
  if(!!_play)    htm+="<param  name     = 'play'    value ='" + _play    + "'>"
  if(!!_menu)    htm+="<param  name     = 'menu'    value ='" + _menu    + "'>"
  if(!!_scale)   htm+="<param  name     = 'scale'   value ='" + _scale   + "'>"
  if(!!_salign)  htm+="<param  name     = 'salign'  value ='" + _salign  + "'>"
  if(!!_wmode)   htm+="<param  name     = 'wmode'   value ='" + _wmode   + "'>"
  htm+=""
  htm+="<embed                          "
  htm+="        pluginspage='https://www.macromedia.com/go/getflashplayer'"
  if(!!_width)   htm+="        width    = '" + _width   + "'"
  if(!!_height)  htm+="        height   = '" + _height  + "'"
  if(!!_hspace)  htm+="        hspace   = '" + _hspace  + "'"
  if(!!_vspace)  htm+="        vspace   = '" + _vspace  + "'"
  if(!!_align)   htm+="        align    = '" + _align   + "'"
  if(!!_class)   htm+="        class    = '" + _class   + "'"
  if(!!_id)      htm+="        id       = '" + _id      + "'"
  if(!!_name)    htm+="        name     = '" + _name    + "'"
  if(!!_style)   htm+="        style    = '" + _style   + "'"
  htm+="        type     = 'application/x-shockwave-flash' "
  if(!!_declare) htm+="                    " + _declare  
  if(!!_swf)     htm+="        src      = '" + _swf     + "'"
  if(!!_quality) htm+="        quality  = '" + _quality + "'"
  if(!!_loop)    htm+="        loop     = '" + _loop    + "'"
  if(!!_bgcolor) htm+="        bgcolor  = '" + _bgcolor + "'"
  if(!!_play)    htm+="        play     = '" + _play    + "'"
  if(!!_menu)    htm+="        menu     = '" + _menu    + "'"
  if(!!_scale)   htm+="        scale    = '" + _scale   + "'"
  if(!!_salign)  htm+="        salign   = '" + _salign  + "'"
  htm+="></embed>"
  htm+="</object>"

  document.write(htm);
}


menuItem = [	["受験するバージョンと試験を選択してください"],
			["選択","Word Specialist(一般レベル)","Excel Specialist(一般レベル)","2科目受験 Word Specialist(一般レベル)とExcel Specialist(一般レベル)","Word　Expert（上級レベル）","Excel　Expert（上級レベル）","2科目受験　Word Expert（上級レベル）とExcel Expert（上級レベル）","PowerPoint","Access","2科目受験　PowerPointとAccess","Outlook"],
			["選択","Word Specialist(一般レベル)","Excel Specialist(一般レベル)","2科目受験 Word Specialist(一般レベル)とExcel Specialist(一般レベル)","Word　Expert（上級レベル）","Excel　Expert（上級レベル）","2科目受験　Word Expert（上級レベル）とExcel Expert（上級レベル）","PowerPoint","Access","2科目受験　PowerPointとAccess","Outlook"],
			["選択","IC3　コンピューティング ファンダメンタルズ","IC3　キー アプリケーションズ","IC3　リビング オンライン","IC3　3科目受験","IC3　2科目受験"],
			["選択","Excel2002 VBA Basic","Excel2002 VBA Standard","Access 2002 VBA Basic","Access 2002 VBA Standard","VBA Professional Office 2003"]
			];

function setMenuItem(n , val_def)
{
	len = document.exam_form.level.options.length;
	for (i=len-1; i>=0; i--)
	{
		document.exam_form.level.options[i] = null;
	}
	for (i=0; i<menuItem[n].length; i++)
	{

		if(i == val_def)
		{
			document.exam_form.level.options[i] = new Option(menuItem[n][i],i , true , true);
		}else{
			document.exam_form.level.options[i] = new Option(menuItem[n][i],i , false , false);
		}

	}
}

