Flash presentation using xml
I was getting tired off the same old Powerpoint presentations
so i started using Flash. It looks great but now i'm trying to
explain to my boss how he can make nice looking presentations to.
There's just one problem he doesn't know anything about Flash.
My idea is to make a flash movie that will display text and
images placed in an XML file. Based on the number off images and
the lenght off the text the slide will have a different layout.
Displaying text and images with XML has not been a problem
but now i'm trying to read the number off images in the XML (1, 2
or 3). Based on the number off images i want to use a different
movie clip for displaying the images. This i can't figure out.
Anybody any ideas how to get this to work or maybe somebody's knows
a good tutorial?
this is straight-forward as long as you have a reasonable xml setup. there are, at least, a couple of ways to reasonably do this. among the least complex structures would be something like:
<slides>
<slide>
<images img1='1.jpg' img2='2.jpg'/>
<text>whatever</text>
</slide>
<slide>
<images img1='1.gif'/>
<text>...</text>
</slide>
</slides>
you would then loop through the attributes of the images node checking for a null attribute to determine the number of images in each slide.
Similar Messages
-
How to embed youtube movie in flash website using xml pages?
hi to every one
I m quite new to flash website designing. so I've downloaded a free flash website template, that is using xml pages in it. & I m using adobe flash cs4. now I wants to embed youtube movie in one of its .xml page & I wants that it shows that movie when i open that xml page in adobe flash cs4. even I've pasted youtube embeded code in one of that xml page but it does not works. so please please please resole my problem as soon as possible.
thousands of thanks to all of those who helped me....
Regards
Faiz Fareed.Maybe you can try You Tube Api for flash
http://code.google.com/apis/youtube/flash_api_reference.html -
Making a jargon buster in flash cs5 using XML
Hi guys !!
I am working o a jargon buster for a college project.
I have written up an XML document like this:
<Items>
<Query>Rip</Query>
<answer>to copy files from a disc onto a computer</answer>
</Items>
Basically the user inputs their query into a editable text field and then flash searches the xml for the query and returns an
answer into a readable text field below.
My problem is how do I get flash to do that??
Thanks in advanced.I suggest you read some XML tutorials. Functionality you desire is one of the easiest to implement once you get a light grasp on XML.
Here is one of the possible approaches:
var xml:XML;
init();
search("Dog");
function init():void
xml = <data>
<Items>
<Query>Rip</Query>
<answer>to copy files from a disc onto a computer</answer>
</Items>
<Items>
<Query>Dog</Query>
<answer>Animal that barks</answer>
</Items>
<Items>
<Query>Watermelon</Query>
<answer>Diuretic</answer>
</Items>
</data>;
function search(searchString:String):void
for each (var node:XML in xml.Items)
if (node.Query.toString() == searchString)
trace(node.Query.toString(), "is", node.answer);
break; -
Is it possible to call a movieClip from the Flash library using XML?
Instead of using "test_1.swf" or "test_2.jpg" in the <IMAGE> tags shown below, we are wanting to call a movieClip from the same library as the .FLA via XML.
Is this possible using XML and AS3?
< ?xml version="1.0" encoding="UTF-8"?>
< all>
< GROUP>
<IMAGE>test_1.swf</IMAGE>
<QUESTION>Question example #1</QUESTION>
<OPTION1>Option A example</OPTION1>
<OPTION2>Option B example/OPTION2>
<OPTION3>Option C example</OPTION3>
<IMAGE>test_2.jpg</IMAGE>
<QUESTION>Question example #2</QUESTION>
<OPTION1>Option A example</OPTION1>
<OPTION2>Option B example/OPTION2>
<OPTION3>Option C example</OPTION3>
< /GROUP>
< /all>data.xml:
< ?xml version="1.0" encoding="UTF-8"?>
< all>
< GROUP>
<IMAGE>MC1</IMAGE>
<QUESTION>Question example #1</QUESTION>
<OPTION1>Option A example</OPTION1>
<OPTION2>Option B example/OPTION2>
<OPTION3>Option C example</OPTION3>
<IMAGE>MC2</IMAGE>
<QUESTION>Question example #2</QUESTION>
<OPTION1>Option A example</OPTION1>
<OPTION2>Option B example/OPTION2>
<OPTION3>Option C example</OPTION3>
< /GROUP>
< /all>
// a.s.
var urlLoader:URLLoader=new URLLoader();
urlLoader.addEventListener(Event.COMPLETE,completeF);
urlLoader.load(new URLRequest("data.xml"));
function completeF(e:Event):void{
var xml:XML=XML(e.data);
var instance:*=stringToClassInstanceF(xml.GROUP.IMAGE[0]);
addChild(instance);
function stringToClassInstanceF(s:String):*{
var C:Class=Class(getDefinitionByName(s));
return new C(); -
On the development version of a site, I have created a flash
movie that uses an XML file that refers to the filenames of images
and their respective captions that are then loaded into the flash
movie.
The images are loaded 2 at a time, into movie containers
within the movie, and then the movies containing the images cycle
through the images one at a time, one movie container fading out
revealing the next image below it, etc. etc.
Basically, I have used this on the site for many photo
galleries. Each one uses the same flash file (in its own folder on
the server, with its respective "images" subdirectory) coupled with
an XML file (all in the same folder on the server) that tells the
flash file where the images are, and in what order, and their
related captions.
There are 9 photo galleries, therefore 9 folders on the
server, each with their own flash and XML and JPEG image files. For
3 specific galleries, the flash file does not load images on some
computers using IE. On the same computers, all other galleries work
fine.
Can anyone even guess what could be causing this??
Many thanks in advance,
ArmoMaybe you can try You Tube Api for flash
http://code.google.com/apis/youtube/flash_api_reference.html -
Adding Polls to Flash Presentations
One of my developers created a Flash presentation using an
online polling system. They have a poll.swf file that contains the
widget and information for the poll, which will be added throughout
the presentation. The polls were done in Flash as well and now they
aren’t mixing well. When called using the loadMovie feature
of Flash the poll.swf does not appear in the main Flash
presentation; however, it does show up in the browser.
Any ideas as to how to get this to work.Thank you for your reply.
How can I convert it to an MP3 file?
Do I have to download software for that? -
How to load images using xml in flash
Hi
im working on a quiz project where i plan to load images using xml in to flash, can any one help with the script with AS2 or 3You'll find a tutorial for what you are after here:
http://www.gotoandlearn.com/play?id=22 -
hi all
It would be appreciated if any one let me know how to edit
bitmap which is imported in flash using xml and save the edited
bitmap back to xml in flash.
Is it posible to save the bitmap data in flash?
thanks in advanceYes you can... but like I said before you need to upload the
data from the changes you make to a server.
In terms of the solution... its unlikely that you'll find one
specifically for your needs. You will have to learn whatever you
don't know how already and maybe adapt some existing examples to
your needs.
To change the visual state of a movie clip... you just do all
the regular things that you want to do to it using flash... scale,
rotation, drawing API , textfields etc in actionscript. If you
don't know how to how to do that stuff, then you need to learn that
first. That's basic actionscript.
You can capture the visual state of a movieclip using the
BitmapData class. That includes a loaded jpeg. You can also
manipulate bimatp data using the same class. You should read up on
that if you don't know how to use it or check out the examples
below for uploading info.
For uploading to the server:
Here's an as2 solution that took 15 secs to find using
google:
http://www.quasimondo.com/archives/000645.php
If you're using as3, google search for "jpeg encoder as3" and
look through that info. There are also historical answers in the
forums here related to this type of thing that might help as
well. -
SetPixel in flash using xml....?
Hi ,
I have tried this in flash i got the result but now i am trying to change the color of the bitmap using setpixel values using xml.
First i am creating a new bitmap and then i have a button when i click on the button the pixel values or the color of the bitmap should be changed.
script for creating a bitmap:
import flash.display.BitmapData;
var myBitmapData:BitmapData = new BitmapData(100, 80, false, 0x00CCCCFF);
var mc:MovieClip = this.createEmptyMovieClip("mc", this.getNextHighestDepth());
mc.attachBitmap(myBitmapData, this.getNextHighestDepth());
Script on the button:
on (release) {
for (var x:Number = 0; x<50; x++) {
for (var y:Number = 0; y<10; y++) {
myBitmapData.setPixel32(x, y, 0x11FF00);
for (var y:Number = 11; y<20; y++) {
myBitmapData.setPixel32(x, y, 0xCCFF00);
for (var y:Number = 21; y<50; y++) {
myBitmapData.setPixel32(x, y, 0x11FFEE);
Now i just want to change the color of the bitmap using setpixel using xml and calling the xml into flash.Hi kglad,
Well i am confused, I am searching that how would be the attributes for setpixel in xml file?How can we assign setpixels from xml.
for example when we load a dynamic data into flash which has three dynamic texts "name_txt,count_txt,type_txt" and when we click on the button "rb_btn" xml data will be loaded into the three dynamic text fields. So below is my code in xml and in flash.
script in xml:
<?xml version="1.0" encoding="utf-8"?>
<Books>
<Book name="Harry Potter" count="1" type="Asian"/>
</Books>
script on first frame:
import flash.display.BitmapData;
var myBitmapData:BitmapData = new BitmapData(100, 80, false, 0x00CCCCFF);
var mc:MovieClip = this.createEmptyMovieClip("mc", this.getNextHighestDepth());
mc.attachBitmap(myBitmapData, this.getNextHighestDepth());
var myXML:XML = new XML();
myXML.ignoreWhite = true;
rb_btn.onRelease = function(success) {
var bookName = myXML.firstChild.childNodes[0].attributes.name;
var bookCount = myXML.firstChild.childNodes[0].attributes.count;
var bookType = myXML.firstChild.childNodes[0].attributes.type;
name_txt.text = bookName;
count_txt.text = bookCount;
type_txt.text = bookType;
myXML.load("colors.xml");
So we are assigning a name in xml called "name="Harry Potter" "we are calling it flash as
"var bookName = myXML.firstChild.childNodes[0].attributes.name;" And my question is how or what is the process to write a code for setPixel in xml and calling it into flash. -
Problems using Flash Presentation / Slide with IE
I have created a slideshow using the Flash presentation /
slide component. All images are the same size. When the movie loads
in Firefox, the slide show works fine. However in IE, the first
image is loaded off center. The top left corner of the image is
placed in the center of the screen. All subsequent images load
fine. This is an intermittent problem as it does not happen all the
time.
Has anyone seen this problem and know of a solution.
Thanks in advance.
JimIs this Virtual Credit Card Number software a website or a stand alone application? If stand alone, then I would recommend installing the Active X (Internet Explorer) version that you can download here: http://get.adobe.com/flashplayer/otherversions
-
Been some time since I have used Flash for anything...
I'm working on a little project to dynamically build a map
and set points of interest on the map. At this time I have the
(mySQL) data being queried and formatted with PHP and pushing the
data to Flash as XML.
In starting the project I'm a bit lost... I mean I have my
data and a good XML format but as it is I'm lost on parsing the
data in Flash and assigning its values to movie clips or other...
I've looked at the Loader Component and the XML Connector
Component and find I can get that to work at all...
My second though was to create a single movie clip on stage
and give it an instance name of "Background" and have it load the
URL of an image given in the attached XML doc... Node "a_zone" and
the value given to attribute "image"... But this brings me back to
square one of not quite understanding Flash and parsing XML... With
this second idea I would use AS to create a movie clip, set it's X
& Y cords and load an image to it based on the XML attributes
listed in the "Gatherable" node (one for each node).
Any suggestions, examples or related info is welcome...
Thanks in advance!Okay, that really wasn't what I was looking for... But I did
go back and RTM :-)
Here's what I have... 1st frame:
2nd Layer: movieclip with the instance name "currentPicture"
The image loads into "currentPicture" from the URL given in
the XML "a_zone" node attribute "image" just fine....
But I'm not able to grab the attributes of each "Gatherable"
node it seems... am I missing something or just not pointing to the
right node?
I keep getting:
undefined
undefined
undefined
Error opening URL
"file:///C|/apache2triad/htdocs/gatherer/flash/undefined"
Error opening URL
"file:///C|/apache2triad/htdocs/gatherer/flash/undefined"
Error opening URL
"file:///C|/apache2triad/htdocs/gatherer/flash/undefined" -
Using Microsoft Notebook presenter mouse 8000 to control a Flash presentation
Hi,
I am building a Flash presentation and would like to control it by using the "next"and "previous" keys on my mouse... I know that it should be something like "on (release) ...", but I am not sure....
Any tips on how to create this in action Script 2.0 ?
Thanks in advance for your help !
Gilbert GourI'm running into that problem right now. I really like the mouse, but I've got to get it working with Keynote, else, I'll have to return the product.
I've tried using Steermouse, but it doesn't seem to be able to remap those those "Presenter" keys. The analysis is able to read the button presses, but the driver isn't able to remap.
If anyone knows of a workaround, please let me know! I'll try Applescript and some other things, but I'm about to give it up and just get a separate presentation tool.
Thanks in advance. -
Error while trying to update the XML template using XML Publisher Administrator
Hello Folks,
We are on R12.1.3
I changed a condition in a report and trying to upload the new XML template using XML Publisher Administrator.
when i click the Apply button, it is throwing an error 'Bad Request'
Navigation : XML Publisher Administrator > Data Definitions > query the report
Click on the name of the report > click 'Update file' besides Data Template > Choose file > Click Apply
I am getting the below error
Bad Request
Your browser sent a request that this server could not understand.
Now, i could not upload a new XML template.
Am I doing anything wrong.
regards,
Krisuser10163762 wrote:
Thank you Eugen and Hussein.
The problem is not with the template.
It seems to be a problem in that particular instance.
Uploaded it in a different instance.
However once i run the program, i cannot view the output as the browser window flashes and disappears.
My colleague says , it is to do with the trusted site to download something from the browser.
Can you please guide me on how to fix this ?
http://bit.ly/1k8e2vi
Thanks,
Hussein -
Possible to Stream a Flash Presentation?
Hi all! I work for a university and we have some faculty that
are creating some huge flash presentations. I know that flash is
remarkably fast when it comes to downloading, but with these large
presentations it's still taking some time. Is it possible to
stream a flash presentation? Compress the audio? Any other
ideas?Never seen TGotoFrame, but there is GotoFrame() and Play(),
which has worked
well for me. Here's a function I've used to change videos in
a Flash movie
from image buttons in the HTML:
<SCRIPT LANGUAGE="JavaScript">
function changeVideo(xname){
if(window.brtv){
window.document["brtv"].SetVariable("theXML", xname);
window.document["brtv"].GotoFrame(0);
window.document["brtv"].Play();
if(document.brtv){
document.brtv.SetVariable("theXML", xname);
document.brtv.GotoFrame(0);
document.brtv.Play();
//-->
</SCRIPT>
Where brtv is the name of the div containing the movie.
Dave -
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/ -
I am a designer working on a flash project that is used to navigate to html pages. The project is a map - when you roll over different states there is an animation making that state pop out and show the state name. When you click each state (Button), it should open an html webpage. Right now the project works great, but I have the url's coded in flash actionscript using "onpress" and "load url." I would like to set it up so the flash file calls the URL for each button from an xml file, so it can be easily edited. The only thing it needs to call is the URL for each button. Can anyone give me simple instructions on how to make that happen?
you'll need to change all the code attached to those buttons so each button has an instance name and you use that name to code for your mouse handler.
and, if you're going to make those changes, you may as well use movieclip buttons and set this up so the next step is easier to accomplish.
Maybe you are looking for
-
Sharepoint 2013 Server Search Not Working, URGENT!!
Hi thr, im a current sharepoint 2013 server user and im facing a severe problem with sharepoint now, i cannot search using the search bar And the Search Service Application keeps giving me this error, 'The search service is not able to connect to th
-
Do i need a new Hard drive? 80gb 6th classic
I just got this used 80gb Ipod classic 6th gen and i noticed that after i sync music to it, all the music is erased the next time i sync, this is my first time owning a ipod (own a iphone) so im new to these, before i made this thread did a google se
-
Send data with profibus (Newbie)
Hi, Im new to labview and have only been working with PLC before so please have patience with my lw knowledge. Im trying to send some data (analog inputs) from labview to my Siemens S7 PLC using a Comsoft profiboard. I have got the communication to
-
I have a Powerbook G4 running on Mac OS X 10.4.11 and have been trying to update our flash player with no luck whatsoever. What aren't we doing right? Help!
-
I have spilt alcohol on my macbok pro and now the mouse does not respond but just clicks randomly. Is it possible to disable it?