⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 faq.htm

📁 基于actionscript3.0的flashLoading控件
💻 HTM
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<link href="shares/help.css" rel="stylesheet" type="text/css">
</head>

<body>
<h1>ControlVR FAQ</h1>
<h4><strong>Q : How do I  load a new object into contolVR with a button? </strong></h4>
<p>A : First you need to give the controlVR component an instance name like <strong>myvr_mc</strong> and place the folowing script on the button.</p>
<pre>
on(release){
	myvr_mc.loadVR(&quot;http://www.mysite.com/objects/myobject.xml&quot;)
}
</pre>
<p><strong>See also</strong> <a href="class/controlvr_loadvr.htm">controlVR.loadVR()</a></p>
<h4>Q : My component gives me a XML Error. How can I see what the Error was?</h4>
<p>A : In the following example you will have to give your controlVR instance a name <strong>vr_mc </strong>and place the following code in the main timeline. The following code will generate a text field that will display any error that the <strong>vr_mc</strong> instance may generate. </p>
<code><pre>
vr_mc.onLoadError = function(error ,code){
	this.createTextField("error_txt",this.getNextHighestDepth(),1, 50, 200, 100);
	this.error_txt.multiline = true;
	this.error_txt.wordWrap = true;
	this.error_txt.border = true;
	this.error_txt.background = true;
	trace(error+code)
	if(error == "XMLLoadError"){
		this.error_txt.text += "sdfdfsgfd"+" : "+code+"\n";
	}
	if(error == "XMLParseError"){

		switch (code){
			case "-2" : this.error_txt.text += error+" A CDATA section was not properly terminated.\n";
				break;
			case "-3" : this.error_txt.text += error+" The XML declaration was not properly terminated.\n";
				break;
			case "-4" : this.error_txt.text += error+" The DOCTYPE declaration was not properly terminated.\n";
				break;
			case "-5" : this.error_txt.text += error+" A comment was not properly terminated.\n";
				break;
			case "-6" : this.error_txt.text += error+" An XML element was malformed.\n";
				break;
			case "-7" : this.error_txt.text += error+" Out of memory.\n";
				break;
			case "-8" : this.error_txt.text += error+" An attribute value was not properly terminated.\n";
				break;
			case "-9" : this.error_txt.text += error+" A start-tag was not matched with an end-tag.\n";
				break;
			case "-10" : this.error_txt.text += error+" An end-tag was encountered without a matching start-tag.\n";
				break;
		}
	}
	if(error == "URLNotFound"){
		this.error_txt.text = error+" : "+code+"\n";
	}
	if(error == "LoadNeverCompleted"){
		this.error_txt.text = error+" : "+code+"\n";
	}
	if(error == "VRObjectError"){
		switch (code){
			case "-2" : this.error_txt.text += error+" Not the same amount of images per layer.\n";
				break;
		}
	}
}
</pre></code>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -