DeveloperBarn Forums

Go Back   DeveloperBarn Forums > Web Design > Multimedia

Discuss "XML file loaded into flash" in the Multimedia forum.

Multimedia - The Multimedia forum is for discussing software such as Photoshop, Fireworks, Shockwave, Flash and other multimedia software used to visually improve your site.


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-05-2008, 12:40 PM
New Member
 
Join Date: Mar 2008
Posts: 86
Thanks: 1
Thanked 0 Times in 0 Posts
Rep Power: 1
peebman2000 is an unknown quantity at this point
Question XML file loaded into flash

Hey everyone its peebman2000, my boss has me doing programming as well as web designing. I think I need a raise. I'm working with flash and actionscript to load text and an image into a flash document, I"m using flash 8. Now I was sent to training for this, but I haven't used it since training; which was like a year ago.

Anyway, i've looked through my training book and online, and I keep getting an error saying:
Quote:
Error opening URL "file:///C:\documents and Settings\peebma\desktop\sfcflash\sfc.xml"
I have a folder that has the images and xml file, but I keep getting this error.

Per what I've found online it might be something with my actionscript, i'm a huge newbie when it comes to actionscript. This is my first time using it for a project.

Does anyone here know a little about actionscript and give any help on what i'm doing wrong?

Let me know and thanks.

XML file:

Quote:
<xml>
<titles>
<title>
<text>Hello</text>
<img>images/bbq.jpg</img>
</title>
</titles>
</xml>
Actionscript:
Code:
menuXml = new XML();
menuXml.ignoreWhite = true;
menuXml.onLoad = function(success) {
	if(success){
		
			
	item = _root.attachMovie("menutitle", "menutitle", 0);
		item._x = 90;
		item._y = 15;
		item.titel_txt.text = this.childNodes[0].childNodes[0].childNodes[0].childNodes[0].childNodes;
		
	}
}
menuXml.load("C:\Documents and Settings\DPeebles\Desktop\osfcflash\osfc.xml");
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-05-2008, 01:13 PM
jmurrayhead's Avatar
Your Lord & Master

 
Join Date: Mar 2008
Location: Reston, VA, USA
Posts: 397
Thanks: 12
Thanked 20 Times in 20 Posts
Rep Power: 1
jmurrayhead is on a distinguished road
Default

I'm not a Flash/action script guy, but I see that your error specifies a different file than what you show in your code. Is it a typo or a problem?:

sfcflash\sfc.xml

osfcflash\osfc.xml

I've also seen a few sites mention how Flash opens files locally. What location do you run this script from? Is it the same location as the xml file? If so, maybe try:

Code:
menuXml.load("osfc.xml");
Unfortunately, I don't know much about Flash. Last time I touched it was back in 1997...and I didn't get very involved with it.
__________________
jmurrayhead
Did I help you out? Make me popular by clicking the icon!

If you found a post helpful, please click the button in the lower right-hand corner of the post.

Powered by ASP.Net
Reply With Quote
  #3 (permalink)  
Old 05-05-2008, 01:24 PM
New Member
 
Join Date: Mar 2008
Posts: 86
Thanks: 1
Thanked 0 Times in 0 Posts
Rep Power: 1
peebman2000 is an unknown quantity at this point
Default reply

Thanks jmurrayhead, I don't know why he has me doing this.

Anyway yes you are correct, I've changed it and saved the flash file in the same folder as the xml file. I know longer get the error, but the images are not showing up in the flash file.

I'm looking up more stuff online on how to display images in flash from a xml file.

If you know anything else, let me know and thanks for the reply.

Quote:
Originally Posted by jmurrayhead View Post
I'm not a Flash/action script guy, but I see that your error specifies a different file than what you show in your code. Is it a typo or a problem?:

sfcflash\sfc.xml

osfcflash\osfc.xml

I've also seen a few sites mention how Flash opens files locally. What location do you run this script from? Is it the same location as the xml file? If so, maybe try:

Code:
menuXml.load("osfc.xml");
Unfortunately, I don't know much about Flash. Last time I touched it was back in 1997...and I didn't get very involved with it.
Reply With Quote
  #4 (permalink)  
Old 05-05-2008, 01:27 PM
jmurrayhead's Avatar
Your Lord & Master

 
Join Date: Mar 2008
Location: Reston, VA, USA
Posts: 397
Thanks: 12
Thanked 20 Times in 20 Posts
Rep Power: 1
jmurrayhead is on a distinguished road
Default

Quote:
Originally Posted by peebman2000 View Post
Thanks jmurrayhead, I don't know why he has me doing this.

Anyway yes you are correct, I've changed it and saved the flash file in the same folder as the xml file. I know longer get the error, but the images are not showing up in the flash file.

I'm looking up more stuff online on how to display images in flash from a xml file.

If you know anything else, let me know and thanks for the reply.
As developers we are often expected to know how to do everything. Just one of the pains of the job lol. If I can think of anything else I'll let you know. Good luck
Reply With Quote
Reply

  DeveloperBarn Forums > Web Design > Multimedia

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Sponsored Links

ASP.NET Resource Index
a directory of ASP.NET tutorials, applications, scripts, assemblies and articles for the novice to professional developer.

Free Web Directory
Including Chats and Forums Resources, Offer automatic, instant and free directory submissions.
URLZ Web Directory
URLZ Web Directory

Free Web Directory - Add Your Link
The Little Web Directory
Free Web Directory
Pegasus free web directory is a free directory organised by categories.


All times are GMT -4. The time now is 01:02 AM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.2.0 RC7
©2008 DeveloperBarn.com

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45