Jump to content

compiled script binary 'resource'


Recommended Posts

I am still playing with Flash based controls.

Simply an embedded web browser object like:

$oIE = ObjCreate("Shell.Explorer.2")

$flashyGUI = GUICreate( "Flashy GUI Example", 640, 480,-1, -1,


$GUIActiveX = GUICtrlCreateObj($oIE, 0, 0 , 640 , 480 )


This IE object I then navigate to a temp HTML document written out by the control like:

$sFilename = @TempDir&"\loadable.html"

$sHTML = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">' & @CRLF

$sHTML &= '<HTML><HEAD></HEAD><body>' & @CRLF

$sHTML &= '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ' & @CRLF

$sHTML &= 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,22,0" ' & @CRLF

$sHTML &= 'id="gsbMovie" width="100%" height="100%">' & @CRLF

$sHTML &= '<param name="movie" value="someMovie.swf">' & @CRLF

$sHTML &= '<param name="bgcolor" value="#FFFFFF">' & @CRLF

$sHTML &= '</object></body></HTML>' & @CRLF





Simple enough and it works fine, but requires two files: the au3 compiled .exe and the 'someMovie.swf' a flash movie.

My question: is there a way to 'add' this binary .swf file as a 'resource' of sorts into the compiled au3 .exe?

That is, like add it as a compiled script resource and when the script is run, write it to a temp file for use in a similar manner to the HTML file above?

Far fetched perhaps but maybe a compiler option I do not yet know about.

Thanks for all the help so far with this.


"Did you ever stop to think? ...and forget to restart!"
Link to comment
Share on other sites

Thanks again my friend lod3n.

That is what I was looking for in all the wrong places apparently; works perfectly.

Keeping you updated, it is a flash control.

So the swf can call AutoIt3 functions as in your IE event call example.

The control/swf is resizable and can even be popped into a kiosk mode.

As well, it can toggle 'tween a "standard control" look and "borderless" as in stripped of all skinning.

And now is a single small .exe file.

So a flash programmer with some knowledge of AutoIt should be able to make complex flash controls.


"Did you ever stop to think? ...and forget to restart!"
Link to comment
Share on other sites

You folks here have created a great resource and wealth of information in this forum, TY.

Now I added rounded corners and dragability to the borderless and titleless Flash GUI.

This looks and acts nice now.

I am running out of things to add, LOL.

Thanks again.


"Did you ever stop to think? ...and forget to restart!"
Link to comment
Share on other sites

Make it do something useful now. Something that flash does well, only have it work with local stuff. Perhaps you could take a look at some of the Example scripts, and see if you slap a shiny new GUI on something someone has already posted.

Or, better yet, create a UDF that lets people make their GUIs with flash instead of windows API (as we do it now)... that would be pretty interesting. You could do a heck of a lot with just buttons, labels, images, animations and text boxes.

[font="Fixedsys"][list][*]All of my AutoIt Example Scripts[*]http://saneasylum.com[/list][/font]

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...