Wow, Bruce - I didn't see that it was you that wrote the reply.  Thank
you much for the help.

I put this "script" in a button definition in a bar, configured as
command "*Script", "If", "(anywindow("C:\*")), with the rest of the
statements in the "More Commands" box.  I understand that I need to
escape the "\".  Now I know I have to do it in expressions.  I hope I
can find something about the "?", which looks like it might be an
operator, in the docs.

As for the "not being able to run it again", I meant a second time,
after it opened the 3 windows and closed them (it's a toggle).  The
next time it did absolutely nothing, but some of the syntax wasn't
right.  I've since put it into a script file.

I saw in Sysinternal's PrcView, Windows Explorer under powerpro and
indented, which I think means that explorer was started by powerpro
and is its child.

Thanks again for your help!
Steve
--- In [email protected], "brucexs" <[EMAIL PROTECTED]> wrote:
>
>  
> > *Script If (anywindow("C:\*"))
> > *Window Close ("C:\*")
> > else
> > exec explorer2 C:\path1
> > exec explorer2 C:\path2
> > exec explorer2 C:\path3
> > endif
> > 
> > The problem is that after the script closes the windows, I can't 
> run
> > it again.  
> 
> I am not sure what you mean by "I can't run  it again.".  Do you get 
> an error message?  Which one?  Or does it just not do what you 
> expect?  If so, what do you expect and what actually happens?
> 
> In any event, the following worked for me, assuming \ is your escape 
> character (ie you are using the standard configuration:
> 
> Script If (anywindow("C:\\*"))
> *Window Close "C:\*"
>  else
> exec explorer2 C:\path1
> exec explorer2 C:\path2
> exec explorer2 C:\path3
> endif
> 
> The confusing fact is that anywindow("...") involves an expression 
> so that the \ must be escaped.  Window close is written in the old 
> command format so you don't need parenthesis or escaping \.
> 
> The following also works, re-written to use dot format for commands, 
> for consistency.  I also used ?" " to avoid having to escape the \.
> If (anywindow("C:\\*"))
> Window.Close ("C:\*")
> else
> exec.explorer2(?"C:\path1")
> exec.explorer2(?"C:\path2")
> exec.explorer2(?"C:\path3")
> 
> 
> 
> 
> Also, I see that explorer.exe remains as a subprocess of
> > Powerpro.
> 
> 
> I am not sure what you mean by this and what tool you are using to 
> make this determination.
>






------------------------ Yahoo! Groups Sponsor --------------------~--> 
Yahoo! Groups gets a make over. See the new email design.
http://us.click.yahoo.com/XISQkA/lOaOAA/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