flash/delphi communication

Posted on 2003-02-20
Medium Priority
Last Modified: 2012-08-13
flash/delphi communication

i need to embed a flash movie into delphi application and i wonder if there is some way to pass parametheres from flash movie to delphi app and backwards.

Anyone know how this is possible?

thanks in advance.
Question by:zastava101
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Expert Comment

ID: 7992198

Accepted Solution

kake26 earned 400 total points
ID: 9170681
Yes you can pass and do tons of stuff to a flash movie in delphi. Here is how.

The first thing you might want to do is import the flash activex control, if you have not done so already. I use delphi 6 personal, and in the past few days I've expiramented alot of delphi/flash stuff. The Import Activex function is under the compnets menu in delphi. Once you see the big ol list box of stuff you have installed on your system. Look for Shockwave Flash! Once you find it proceed to just hit install and all that.  All goes right, under the activex bar in the delphi IDE there will be a new button. Procced to use it as anyother VCLs, I think they are called. If you create on on a form, the easiest way to specify the movie to use is by double clicking on it. Note you can embed the movie, so all you distrubute is the exe. That covers the install and the basic of it, now lets get into the neat stuff you can do. When we installed the flash activex, delphi stripped all the available functions and stuff from the type libs. If you have code completion on try the following after inserting the flash in a form. Minimize the form and any were in the unit display type "ShockwaveFlash1.", let the code completion popup the list of available functions. Note how many there are and what they can do. I typically use the following very often:

From with in flash:
I use fscommand to pass stuff back to the delphi exe its embeded in.

From delphi to flash:
I use the following alot.

ShockwaveFlash1.SetVariable('varname', value: string);
out1 := ShockwaveFlash1.GetVariable('in1'); // were out1: string and in1 is the flash var you wish to get

Those are the basic 3 I use alot, of course I suggest you do the code compltion thing to see the whole list. You will find you can manipulate practically everything in a flash movie from delphi.

End note: There is an issue I've encountered when having the main form spawn another form with the same flash movie in it. In that case some simple glue code is required, if you wish to pass data between both windows.

I hope this sheds light on your issue if you have further questions let me know.
LVL 10

Expert Comment

ID: 9947712
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area for this question:
       to accept kake26's answer
Please leave any comments here within the next seven days.


Some days and here is the Christmas Time. I wish good luck and good health for you all and for your loved ones

EE Cleanup Volunteer

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question