--- John wrote:

> I really appreciate this... I was wondering if you could explain
> what all the script is doing so that I can modify it to work with
> EditPlus, so that when I'm editing a file in EditPlus, I could
> easily send it to Dreamweaver. Or in any other program. Thanks a
> bunch! It works great in Irfanview!

The idea of the script is to copy the full file path of the currently
loaded file from the first available standard Windows control.

IrfanView's Image Properties box contains an array of standard Windows
controls, one of which contains the full path of the current file. If
such a window exists in EditPlus or if the main EditPlus window
contains a control with the full path somewhere, then the script
shouldn't be too hard to modify to accommodate that.

--- I wrote:

> ; --- all one line below
> Local Fireworks = ?"%ProgramFiles%\Macromedia\Fireworks
> MX\Fireworks.exe"
> ; --- all one line above

The first line there sets the path to Fireworks�� you can of course
change the contents of this variable to any other program, or even
change the name of the variable to e.g. �Dreamweaver� if you also
change the line near the end that references it.

> If(Win.ChildTextByIndex(?"Active", 4) != ?"No file loaded") Do

This is a simple validation check. We are looking at the contents of
the leftmost panel of IrfanView's status bar. If it reports �No file
loaded� then we won't carry out the rest of the script since it won't
work.

> Win.Keys(?"i")

Sends �I� to IrfanView's window.

> Local Caption = ?"IrfanView - Image properties"

This is the precise caption of IrfanView's Image Properties window.
Since we are referencing it a couple times I plonked it into a
variable but this isn't necessary.

> Wait.For(VisibleWindow(Caption))

We can't look at the window's controls until the window is visible.

> Local FilePath = Win.ChildTextByIndex(Caption, 4)

Control no. 4 is the text field that contains the information we want.
The above command reads that information into the FilePath variable.

> Win.Close(Caption)

We close the Image Properties window now that we're done with it.

> Do(Fireworks, FilePath)

And we launch Fireworks.

> EndIf

This belongs to the �No file loaded� check above.

-- 

Alex Peters / Melbourne, Australia
PowerPro v4.1.00 / Windows XP



------------------------ Yahoo! Groups Sponsor --------------------~--> 
$9.95 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/J8kdrA/y20IAA/yQLSAA/JV_rlB/TM
--------------------------------------------------------------------~-> 

Attention: PowerPro's Web site has moved: http://www.ppro.org 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/power-pro/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to