Record or output SWF from dynamic SWF
Hello everyone
I have a SWF that pulls images from a database and dynamically creates a slideshow. Each time the URL is loaded with different parameters, a new slideshow is shown.
I was wondering if it is possible to record or output a SWF - for each dynamically generated slideshow?
Meaning: The original slideshow is dynamically generated and at the same time, a copy of that slideshow is recorded and or an output of a second SWF is performed....
Is that possible??
Thank you for your time and attention
1. You can't bind in the table name. You would have to use string concatenation for the table_name. But should still use binds for the variable.
2. The syntax for execute immediate is not
execute immediate 'select into ...'but
execute immediate 'select ....' into variable.extending your example to include the table_name, you would end up with something like this:
set serveroutput on;
declare
myvar varchar2(200);
mytablename varchar2(30) := 'DUAL';
secondvar number;
begin
EXECUTE IMMEDIATE 'select 1 from '|| mytablename ||' where rownum = 1' into secondvar; --using 'using' if binding in the variable for a predicate
dbms_output.put_line(secondvar);
end;Edited by: dombrooks on Sep 23, 2009 4:17 PM
Similar Messages
-
How to unload swf from anather swf
I am calling 3 different swf in to test.swf.
now i want to unload only 1 swf from test.swf
can any 1 tell me how it is possible i am trying
with removeMoviClip() and unloadMovie()
but its of no use.
regards
JustbipinMaybe that's not really what you're doing?
I would guess you rather have
loadMovieNum("myFiLe.swf",99);
This would be unloaded with
unloadMovieNum(99);
Good luck
Wolf
PS Or do you have a container movieClip called "99" to fool
us all? :-)
PPS watch your capitalization. If you call a file "myFiLe"
(and mis-spell it somewhere) it might work on Windows, but not on
Unix-derivatives. A potential source of "Why did it work when I
tested it but not when I uploaded it?" -
RemoveChild in parent.swf from child.swf (AS3)
Hi! How do I remove a child from a parent timeline with an externally-loaded swf? Specifically, I have a main.swf that loads movie_1.swf and movie_2.swf. In the movie_1.swf, I have a button to remove movie_2.swf from main.swf.
//--------- main.swf code:
var loader1:Loader = new Loader();
var loader2:Loader = new Loader();
loader1.load(new URLRequest("movie_1.swf"));
loader2.load(new URLRequest("movie_2.swf"));
addChild(loader1);
addChild(loader2);
//------------- movie_1.swf code:
removeMovie2_btn.addEventListener(MouseEvent.CLICK , removeMovie2);
function removeMovie2(event:MouseEvent):void
this.parent.parent.removeChild(this.loader2); // this does not work (get error code 2007, "Parameter child must be non-null")
// Thank you!Here's how your code will change:
//--------- main.swf code:
var loader1:Loader = new Loader();
var loader2:Loader = new Loader();
loader1.contentLoaderInfo.addEventListener(Event.COMPLETE, assignMovie1Listener);
loader1.load(new URLRequest("movie_1.swf"));
loader2.load(new URLRequest("movie_2.swf"));
addChild(loader1);
addChild(loader2);
function assignMovie1Listener(evt:Event):void {
MovieClip(evt.currentTarget.content).addEventListener("eventTriggered", removeLoader2);
function removeLoader2(evt:Event):void {
loader2.unloadAndStop();
removeChild(loader2);
//------------- movie_1.swf code:
removeMovie2_btn.addEventListener(MouseEvent.CLICK , removeMovie2);
function removeMovie2(event:MouseEvent):void
dispatchEvent(new Event("eventTriggered")); -
Error when opening swf from another swf
Hi all,
I'll try to explain this as good as possible.... I made a maze game that works perfectly when I run it by clicking on it's own .swf file, but when I try to access it from another .swf file which is a menu for the games I created, it does not work.
I have absolutely no idea where to look for the error, so my question is: can it be that the main.swf (which is the menu for games) could be the problem, or the problem must be in the maze.swf?
Thanx in advance!no, all code is in the first frame of actions layer:
stop();
var rightArrow:Boolean = false;
var leftArrow:Boolean = false;
var upArrow:Boolean = false;
var downArrow:Boolean = false;
var speed:int = 5;
stage.addEventListener(KeyboardEvent.KEY_DOWN, stage_onKeyDown);
stage.addEventListener(KeyboardEvent.KEY_UP, stage_onKeyUp);
stage.addEventListener(Event.ENTER_FRAME, stage_onEnterFrame);
function stage_onKeyDown(event:KeyboardEvent):void {
if(event.keyCode == Keyboard.RIGHT) rightArrow = true;
if(event.keyCode == Keyboard.LEFT) leftArrow = true;
if(event.keyCode == Keyboard.UP) upArrow = true;
if(event.keyCode == Keyboard.DOWN) downArrow = true;
function stage_onKeyUp(event:KeyboardEvent):void {
if(event.keyCode == Keyboard.RIGHT) rightArrow = false;
if(event.keyCode == Keyboard.LEFT) leftArrow = false;
if(event.keyCode == Keyboard.UP) upArrow = false;
if(event.keyCode == Keyboard.DOWN) downArrow = false;
function stage_onEnterFrame(event:Event):void {
var rect:Rectangle = player.getBounds(this);
var i:int = 0;
var xBump:int = 0;
var yBump:int = 0;
if(rightArrow) {
xBump = speed;
for(i = 0; i < speed; i++) {
if(maze.hitTestPoint(rect.right + i, player.y, true)) {
xBump = i - 1;
break;
if(leftArrow) {
xBump = -speed;
for(i = 0; i < speed; i++) {
if(maze.hitTestPoint(rect.left - i, player.y, true)) {
xBump = -i + 1;
break;
if(upArrow) {
yBump = -speed;
for(i = 0; i < speed; i++) {
if(maze.hitTestPoint(player.x, rect.top - i, true)) {
yBump = -i + 1;
break;
if(downArrow) {
yBump = speed;
for(i = 0; i < speed; i++) {
if(maze.hitTestPoint(player.x, rect.bottom + i, true)) {
yBump = i - 1;
break;
player.x += xBump;
player.y += yBump;
if(rightArrow) {
xBump = speed;
for(i = 0; i < speed; i++) {
if(cilj.hitTestPoint(rect.right + i, player.y, true)) {
xBump = i - 1;
nextScene(); -
Control swf from separate swf in main file
Im loading 2 swfs into my main swf. So I have a top swf and a
bottom swf being loaded in externally into my main swf that makes 3
swfs, 1MAIN swf loading TOP swf & BOTTOM swf.
Is there a way to have the bottom swf control or command the
top swf? I need a button on in the bottom swf to tell the top swf
to load a movie.in AS2 you can point directly from one to the other with the
correct pathing.
IE:
_level0.TopSwfLoader.content.FunctionToCall();
or
_level0.TopSwfLoader.content.Property = NewPropertyValue;
_level0 takes you to the main swf (_root, but this works
around if lockroot is set)
TopSwfLoader.content is the content of the Loader component
that has your Top.swf loaded into it. If you are not using a Loader
component, then you can change this to the instance name of the
Movie Clip that has the swf loaded into it.
FunctionToCall()/Property is what you want to control. Either
a function call or a property.
In AS3 this works a bit differently. I would dispatch a
custom event from the Bottom swf. Then the main swf would catch
that event, and call the appropriate function/property in the top
swf. I can elaborate more on this if you need. -
Having problem controling resizing of a swf from another swf
I'm trying to build a site where all the pages are full browser and maintain aspect ratio. I would like to control the resizing from the menu page. The resizing works fine from the page that's being resized but when I try to let the parent swf do that it has issues.
Here's what the home page looks like with the controls built in http://www.mespinach/example1/
This example is the site it has a menu page that I open the others from I remove the resizing code from the home page and try to resize from menu.swf.
here's the code from menu.swf
stage.align = StageAlign.TOP_LEFT;
stage.scaleMode = StageScaleMode.NO_SCALE;
var holder:btnHolder = new btnHolder();
addChild(holder);
stage.addEventListener(Event.RESIZE, moveHolder);
moveHolder();
function moveHolder(e:Event = null):void {
holder.x = stage.stageWidth - (holder.width +25);
holder.y = 50;
holder.mcHome.buttonMode = true;
holder.mcAbout.buttonMode = true;
holder.mcMovies.buttonMode = true;
//holder.mcLocation.buttonMode = true;
holder.mcStore.buttonMode = true;
//var objFileToLoad:URLRequest = new URLRequest();
var swfLoader:Loader;
addListeners();
function addListeners():void {
holder.mcHome.addEventListener(MouseEvent.CLICK, homePage);
holder.mcAbout.addEventListener(MouseEvent.CLICK, aboutPage);
holder.mcMovies.addEventListener(MouseEvent.CLICK, moviesPage);
// holder.mcLocation.addEventListener(MouseEvent.CLICK, locationPage);
holder.mcStore.addEventListener(MouseEvent.CLICK, storePage);
var currentPage:*;
var xImage:Sprite = new Sprite();
homePage();
function homePage(event:MouseEvent = null):void {
SoundMixer.stopAll();
addListeners();
if(swfLoader){this.removeChildAt(0);}
holder.mcHome.removeEventListener(MouseEvent.CLICK, homePage);
var loadRequest:URLRequest = new URLRequest("home.swf");
swfLoader = new Loader();
swfLoader.contentLoaderInfo.addEventListener(Event.INIT, positionContent);
swfLoader.load(loadRequest);
this.addChildAt(swfLoader, 0);
function positionContent(e:Event):void {
currentPage = swfLoader.content;
var loadedImage = currentPage.onStage;
xImage = loadedImage;
// loadedImage.x= 0;
// loadedImage.y= 0;
fillBG();
function aboutPage(event:MouseEvent):void {
SoundMixer.stopAll();
var objFileToLoad:URLRequest = new URLRequest("about.swf");
loader.contentLoaderInfo.addEventListener(Event.INIT,positionContent);
loader.load(objFileToLoad);
this.addChildAt(loader, 0);
function positionContent(e:Event):void{
loader.x= 0;
loader.y= 0;
function moviesPage(event:MouseEvent):void {
addListeners();
holder.mcMovies.removeEventListener(MouseEvent.CLICK, moviesPage);
SoundMixer.stopAll();
if(swfLoader){this.removeChildAt(0);}
var objFileToLoad:URLRequest = new URLRequest("Movies.swf");
swfLoader.contentLoaderInfo.addEventListener(Event.INIT,loadedHandler);
swfLoader.load(objFileToLoad);
this.addChildAt(swfLoader, 0);
function loadedHandler(e:Event):void {
currentPage = swfLoader.content;
xImage = currentPage;
function locationPage(event:MouseEvent):void {
SoundMixer.stopAll();
var objFileToLoad:URLRequest = new URLRequest("location.swf");
loader.load(objFileToLoad);
this.addChildAt(loader, 0);
function storePage(event:MouseEvent):void {
SoundMixer.stopAll();
var objFileToLoad:URLRequest = new URLRequest("store.swf");
loader.load(objFileToLoad);
this.addChildAt(loader, 0);
holder.addEventListener(MouseEvent.MOUSE_OVER, over);
holder.addEventListener(MouseEvent.MOUSE_OUT, out);
holder.addEventListener(MouseEvent.MOUSE_DOWN, down);
holder.addEventListener(MouseEvent.MOUSE_UP, up);
holder.mcAbout.buttonMode = true;
holder.mcHome.buttonMode = true;
holder.mcMovies.buttonMode = true;
holder.mcStore.buttonMode = true;
//holder.mcLocation.buttonMode = true;
var myColor:ColorTransform = transform.colorTransform;
function over(e:MouseEvent):void {
myColor.alphaMultiplier = 3;
e.target.transform.colorTransform = myColor;
function out(e:MouseEvent):void {
myColor.alphaMultiplier = 1;
e.target.transform.colorTransform = myColor;
function down(e:MouseEvent):void {
myColor.alphaMultiplier = 5;
e.target.transform.colorTransform = myColor;
function up(e:MouseEvent):void {
myColor.alphaMultiplier = 1;
e.target.transform.colorTransform = myColor;
//var cpc = this.child.child.getChildByName("onStage");
//trace(cpc);
var ratio:Number;
var rRatio:Number;
ratio = xImage.height/xImage.width;
rRatio = xImage.width/xImage.height;
var newRatio:Number;
function fillBG(evt:Event = null):void {
trace("width: " + xImage.width);
trace("height: " + xImage.height);
trace("ratio: " + ratio.toString());
trace("rRatio: " + rRatio.toString());
trace("newRatio: " + newRatio.toString());
newRatio = stage.stageHeight/stage.stageWidth;
holder.x = stage.stageWidth - (holder.width +25);
holder.y = 50;
if (newRatio > ratio) {
trace("newRatio > ratio: ");
xImage.height = stage.stageHeight;
xImage.width = stage.stageHeight * rRatio;
} else {
trace("else");
xImage.width = stage.stageWidth;
xImage.height = stage.stageWidth * ratio;
stage.addEventListener(Event.RESIZE, fillBG);
messages from trace statements here:
width: 939
height: 704
ratio: NaN
rRatio: NaN
newRatio: NaN
else
width: 561
height: 704
ratio: NaN
rRatio: NaN
newRatio: 0.49376114081996436
else
The height never changes
retio and rRatio are NaN even though they are the Quotient of numbers.First, it is too much code to go through so I don't think I will give a complete answer. I assume this is a timeline code.
Here is what I was able to notice:
1. You declare the variables outside the scopes of the functions:
var ratio:Number;
var rRatio:Number;
ratio = xImage.height/xImage.width;
rRatio = xImage.width/xImage.height;
var newRatio:Number;
Naturally, they are NaN because neither xImage.height nor xImage.width are available at this point.
I suspect that you anticipate that when code hits these lines - swf is already loaded but IT IS NOT. Flash executes ALL THE CODE to the end NOT WAITING for swf to load - this is one of the premises of asynchronous event model.
To remedy this you need to place value assignments into the event handler:
Version One:
Declare variable at the top of the code before you start loading:
var ratio:Number;
var rRatio:Number;
var newRatio:Number;
Calculate values in event handler:
function positionContent(e:Event):void {
ccurrentPage = swfLoader.content;
var loadedImage = currentPage.onStage;
xImage = loadedImage;
ratio = xImage.height/xImage.width;
rRatio = xImage.width/xImage.height;
fillBG();
Or do it inside fillBG(); method (version two)
2. Nested functions are evil and I would like to suggest you reconsider using them and bring them outside of other methods' scopes. I am talking about positionContent handlers you use. -
Alright so i'm fairly new to AS3 and flash in gernal, have done a bit of work in flash but nothing this major and need some help. I have a longtail flash player setup to a rtmp server to stream live events using adobe flash encoder 3. In gerneral it works fine now the problem is content i have a second swf file within the same page that was a powerpoint presentation that is now converted to a swf.
What i need to do is somehow send a command from the longtail video player to the slide show to trigger a slide push. So lets say we are live and streaming away i would need to send some sort of command that will tell the second swf to change slides so that everything is in sync.
Currenty we are using Windows media enncoder and we just send out a command to a iframe within the encoder which changes the slide, the slides are JPG so its easy to do. In the testing stage we have a standalone slide controller that is linked to the iframe and we can push a slide from the contoller which push the slide on the iframe. This method works if i remove wmp and put in a flash place since it not going through a video stream, but i need it to go through the video stream and then tell either a swf to change a slide or an ifreame to change a slide.
Reason it has to go through the video stream is so we can record the video and the commands so they can be setup as archive, so video and slide will cue at the right areas. Just like how you can send out commands from within windows media encoder and archive them and they auto trigger once he video plays.
Well i just need a way that will sync video with slides i don't really care how its done just that its done. There has to be a way to record the slide push commands so they can be used again to play the video and so it advances the slides.
PS this is related to my JobIf you want to inject metadata into a life stream, you, perhaps, need to look into Flash Interactive Server. This forum is not a server forum tough. Managing FMS is a special skill/knowledge set. There is FMS forum.
-
Controlling swfs from other swfs.
hi there. the site i've designed has a background layer, a
navigation panel layer(menu) and the content is loaded as separate
swf files on levels behind the navigation panel. to allow for
seamless unload of the content i want to control the transition
from the navigation panel layer.
eg. When the user clicks on "Story" button, the navi panel
layer communicates with the content layer (eg. Welcome page), tells
it to play from frames 50-60 and then unload. After this, the
desired content layer (in this case "Story") is loaded into, say
layer 5.
how do i go about coding this in actionscript? i'm slightly
bamboozled by the actual script for it and i'd really appreciate
some direction.If you load your movieClips into levels, you simply use those
levels to direct them, e.g. _level5.gotoAndPlay(50)
You can't tell a movieClip to play from frame 50 to 60 and
then stop. I mean you could, but judging from the question you ask
I guess you don't want to get into so much complexity.
You tell the clip to play, and the clip should know itself
when to stop. If you want to be a bit more flexible, you can set a
variable in the clip and check it at certain keyframes via
actionscript:
in the controlling clip:
_level5.stopFrame = 60;
_level5.gotoAndPlay(50);
And in the controlled clip in possible stop frames:
if(stopFrame == _currentframe) { stop(); }
You could enable this for every frame via an onEnterFrame
event handler.
Of course you need to tell the controlling clip to continue
in some way, e.g. by sending it to another frame....
This of course is very linear and old style programming, not
object oriented.
It would be better not to load into levels, but into named
movieClips at certain depths. This allows you to use the
movieClipLoader class, and program all that event-driven. -
OUTPUT variable from dynamic query with openquery
I am working on a dynamic sql statement that uses openquery to retrieve some columns from an Oracle source. My goal is to take the variables from the select openquery statement and store them, so they can be passed to an insert statement. I am
having no problem getting the emplid but the first_name and last_name are NULL
Any help would be appreciated.
DECLARE @sql nvarchar(max)
declare @emplid varchar(11)
declare @first_name varchar(50)
set @emplid = '1234'
BEGIN
SET NOCOUNT ON;
SET @sql = 'select distinct emplid,
First_name ,
Last_name
from openquery(DWHCRPT, ''select p.emplid, p.First_nAME, p.last_nAME
FROM PS_OCC_BIODEMO_S P
where P.emplid = ''''' + @emplid + ''''''') A';
EXEC SP_executesql @SQL, N'@emplid VARCHAR (11), @first_name varchar(50) OUTPUT', @emplid, @first_name = first_name;
select @emplid, @first_name --currently returning NULL
ENDPatrick's query would work, but it would drag the entire table over to SQL Server, which could be expensive.
The code you posted have several flaws. You are not assigning @first_name, and you have failed to provide OUTPUT for the actual parameter. Also, the DISTINCT looks out of place. Isn't emplid a key?
This should work better:
SET @sql = 'select @first_name = First_name
from openquery(DWHCRPT, ''select p.First_nAME, p.last_nAME
FROM PS_OCC_BIODEMO_S P
where P.emplid = ''''' + @emplid + ''''''') A';
EXEC SP_executesql @SQL, N'@emplid VARCHAR (11), @first_name varchar(50) OUTPUT', @emplid, @first_name = @first_name OUTPUT;
select @emplid, @first_name --currently returning NULL
Also, look at this link for some tips how to write queries with OPENQUERY without going insane over all nested quotes:
http://www.sommarskog.se/dynamic_sql.html#OPENQUERY
Erland Sommarskog, SQL Server MVP, [email protected] -
GotoAndPlay specific frame in external swf from main swf
I have a main swf that loads 2 external swfs.
I click on button to see content of external swf #1 and see stuff. I do something that causes external swf to show other stuff (i.e. not at beginning state)
In the main swf I click on button to see content of external swf #2. External swf #1 content is made invisible and I see content of external swf stuff.
NOW, if I click on button to take me back to see external swf #1, I see it's content in current state. I want to force it to start over again at frame #1 which will reset content.
However, no matter what I try, I can't seem to control which frame to go to in external swf using gotoAndplay.
Here is code in frame #1 of main swf to load external swfs:
//load academic movie
var swfLoader1:Loader = new Loader();
container1.addChild(swfLoader1);
var url1:URLRequest = new URLRequest("academic.swf");
swfLoader1.load(url1);
//load wisdom movie
var swfLoader3:Loader = new Loader();
container3.addChild(swfLoader3);
var url3:URLRequest = new URLRequest("wisdom.swf");
swfLoader3.load(url3);
Here is code in frame 2 of main swf that checks button to see where to go in external swf:
//academic button clicked
function academicClick(event:MouseEvent){
container3.alpha = 0;
container3.visible = false;
container1.visible = true;
container1.gotoAndPlay(1); //this is where I am trying to force it to start at frame 1
container1.alpha = 1;
I don't want to reload the external movie to force it to start over.
Any help would be much appreciated.You can easily control this by making the external swf to load with your movieclip, The below is the code snippet that clear on accessing the specific frame on external swf.
//Loading clips content
var ldr:Loader;
var mcExt:MovieClip;
//Loading
loadswf("external.swf");
function loadswf(tmp:String):void{
unloadSwf();
ldr= new Loader();
ldr.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, progressListener);
ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, swfLoaded);
ldr.load(new URLRequest(tmp));
function progressListener (e:ProgressEvent):void{
ploader.visible=true;
function swfLoaded(e:Event):void {
mcExt = e.target.content as MovieClip;
ldr.contentLoaderInfo.removeEventListener(Event.COMPLETE, swfLoaded);
mcExt.addEventListener(Event.ENTER_FRAME,onEnterfn);
ploader.visible=false;
addChild(mcExt);
//UnLoading
function unloadSwf():void{
if (ldr!=null){
ldr.unloadAndStop();
removeChild(mcExt);
mcExt=null;
//Intervals (The part you work on the specific frame within the external swf
function onEnterfn(e:Event):void{
var num:int=mcExt.currentFrame;
if (num==1) mcExt.play();
if (num==9) {
mcExt.skipmc.addEventListener(MouseEvent.CLICK,skipfn);
function skipfn(e:MouseEvent):void{
mcExt.stop();
mcExt.removeEventListener(Event.ENTER_FRAME,onEnterfn);
gotoAndStop("help");
if (num==mcExt.totalFrames){
mcExt.removeEventListener(Event.ENTER_FRAME,onEnterfn);
gotoAndStop("help");
hope it solve -
Hello Readers,
I have been working on an application.
There is a login screen for the application, in one of the swf's I have been writing the login code, along-with communications with XML.
Now once the user has been validated, I want to redirect the user to some XYZ.swf file and close the login.swf file else if not then I have to display an error message.
The issue may sound simple, but I am a beginner at this.
I would be encouraged to explore my endeavors, if some one could help me out with it.
Thank You for reading.
Regards,
Jayesh SidhwaniAbsolutely! Yup, you got it! If you want to use a SWF with all its script and interactions, you have to put it in another place and treat it as an external URL. It has to be boss of its territory (I almost said 'domain' but of course it can be in the same domain).
Go navigateToURL() and you have no problems.
The problem is, we often want to load a SWF without navigating outside our main compiled SWF, and it's frustrating to find out that it loads but doesn't use its timeline code. When you want to do this, you should forget using a SWF and make the object an MC instead. -
Reference to main.swf from nested swf
Hi,
I have main.swf that loads page.swf . I want to have a button
inside page.swf that tells main.swf to do something.
How do I refernce the timeline of Mian.swf
I use mx2004
Thanks,
RobertSee:
http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?catid=194&threadid=1173850&en terthread=y
If you target what you want to do just like if it was in the
same swf. The mc you want to load won't work correctly until it's
tested in the movie your loading into. Like my code. _root with dot
in between each nested element. My code has the an empty mc called
'empty' that MARK_EXPAND is loaded into. And 'empty' is nested in
'InterfaceYO' which is nested in HEADERfadeout which in turn is
(obviously) in the _root, which is the source. -
How to pass a "Button" reference in one swf to anthor swf file?
Dear all:
Please let me describe my problem first.
In my application, there are two swf files:"sender.swf" and
"receiver.swf"
A button named "re_Button" is in "receive.swf", and now i
wanna operate the "re_Button" through the "sender.swf".
How to do this?
Can I access the "re_Button" reference through another swf
application??
And I've tried the "locaconnection" class, but it doesn't
help.
AnyOne helps me?
Thanks in advance -_-I tried the localconnection class:
1).Sender.as:
private var send_tf:TextField;
private function sendMessage(event:MouseEvent):void {
conn.send("myConnection", "lcHandler",send_tf); // to send
the "send_tf" reference to the "Receiver"
2). Receiver.as
public function lcHandler(tf:Object):void {
tf as TextField ==null // here, i find that the "send_tf" is
not a "TextField" any more!!!!!!!!!!!!!!!!
I wanna operate one instance reference in one swf from
another swf.
Is it possiable??
Thanks in advance. -
Dynamically load content into a "template" swf from text file
I have a dream....
Well, I have a concept. I have not actively pursued Flash in
several years, though I've continued to have it in my arsenal. I've
not done much in the action scripting realm for a while though.
I am trying to create a template that will be used for about
100 different product pages.
It would have two tabs, basically, 2 different graphical
button sets. One will have up to 4 links to similar products, each
tab will be on the side of a square, and I need the ability to not
display a tab if there is no actual link.
As for the other tab, Its a menu that consists of a series of
lines. This can be an external menu, I just need a way to have
flash load the right menu. This menu, when you mouse over a line,
the name of the product appears, as well as a product image that
gets loaded with the menu. The product images would be external,
allowing me to simply replace an image if a new higher end version
of the product comes out.
So, I am totally not an actionscripter. Looks like I need to
load variables from an external file. Can I set a property in the
flash code on the html that tells the movie what dataset to grab
from?
Here's basically what I am looking for
property: value
(load variables for:)
item: 44
(menu1)
faster: 54b.html
slower: 34d.html
left: 43d.html
right: 45c.html
(menu2)
menu:graph5.swf
(menu loads images from external source)
link51: 51d.html
link52: 52c.html
link53: 53c.html
link54: 54d.html
link55: 55b.html
link56: 56d.html
A possible third menu would be text driven, and would use
html to link to various items.
This is a static site, so urls will be fixed.
Is it best to build a php page that serves up data for a
single item, or do one big text file with all 100 or so items? Is
that even possible?
My Flash since MX is very rusty. I am using Flash Pro8. I
would love to create a single file so modifications are to the text
files, unless a new item is released, then it's updating a single
flash menu and updating the text file.
Been spending way too much time in InDesign lately! I used to
be pretty good at Flash!well sorry there fanmap - but I don't think you're going to
be able to get this to work. here's why: the link points to a php
file - which gathers dynamic info from a DB - the return from the
php is generating a string that is based on the DOM and
'constructs' a javascript method that in turn writes to the html
document. although we can embed html into a textField in Flash
there are a limited number of supported html tags - and JS methods
will not operate internally. in addition, (i'm not certain someone
correct this if i'm off) there's no way to 'change' the output of
the php call, therefore you will not be able to read the return
because it is designed to use the DOM and write solely to the
current document. Even if you were to access the JS method from the
swf file (which one can) it will still only write the content of
the php return to the html document - and the output is not
compatible with the textField class. -
How to read .xml file from embedded .swf(flash output) in captivate
I have been trying to read .xml file from the .swf (Flash output) that is embedded within the captivate file but no luck yet . Please if anyone got any clue on how get this thing done using Action script 3.0 then let me know. I am using Adobe Captivate 5.5 at present and Flash CS 5.5.
I am well aware about how to read .xml file through action script 3.0 in flash but when insert the same flash in captivate and publish nothing comes in captivate output. I would higly appreciate if anyone could help me out with that.
Here is is graphical demonstration of my query :
Message was edited by: captainmkvHi Captainmkv,
Does the information in this post cover what you're trying to do: http://forums.adobe.com/message/5081928#5081928
Tristan,
Maybe you are looking for
-
Hi, I have a Solaris 11.1 T4 server. I created a 'flar' from a Solaris 10 (U7) server and created a Solaris 10 zone on the T4. zonecfg has the IP address configured (can't copy and paste) correctly. The global zone has net1:1 configured with the IP a
-
MacBook doesn't detect music cd or open iTunes
I have tried unsuccessfully to put new music onto my iTunes. When I insert a CD nothing happens. I have gone into System Preferences and it has IGNORE when you insert a music CD. I keep changing it back to open iTunes,but it keeps reverting back to I
-
Error Message : Condition type is not maintained in the schema RM0002
HI Gurus, I have created a new purchasing procedure as follows. ZVATV : <b>Condition Schema</b> VATV : <b>Condition Type</b> VA : <b>Sch.Grp Vndr</b> When I create the Purchase order, the above mentioned schema, ZVATV is automatically determined. Bu
-
Adobe Error- when trying to display the form in english login
Hi, I have made few changes in the adobe form in italian login (since that was its original language) it is working fine in italian login while generating an error in english login.The error is shown below- "ADS: Request start time: Tue Sep 15 06:37
-
I found this on intenet and meets my needs, except I want to add Title // set random # variables - each must be 0 for first 'while' loop below var randomNum = 0; var randomNumLast = 0; // parent container var container_mc = this.createEmptyMovieClip(