--- In [email protected], "Nick Valman" <[EMAIL PROTECTED]> wrote:
>
> Sorry for being a little bit abrupt in my previous post.
>
> I was looking at some scripts at http://ppro.totalcmd.net/ in order
> to learn how to write my own. Most of those scripts require the
> tc.dll (total commander) and childwin.dll plugins. I do believe
> those plugins are not necessary so I am trying to find the
> equivalent of the following two statements:
>
> 1) Panel = ifelse(tc.active(hwnd) == "left", 8, 7) // for me those
> numbers are 5 and 4.
> 2) ... = childwin.handle(hwnd, "TMyListBox", Panel)
>
> I have found how to get the handle of one of the TC listboxes
> (equivalent to the second statement) :
>
> ... = Win.handlefromindex("c=TTOTAL_CMD", Panel )
>
> But I haven't been able to find out how to replace the 1st
> statement. Any idea? :?
>
> If I had any documentation about tc.dll then I perhaps I would be
> able to find the solution by my own. But I am not that expert to
> figure out what exactly tc.active(hwnd) does and how to replace it.
>
> I feel that the solution is really simple. But I cannot see it :|
As I don't have these scripts/dlls, I can't tell for sure, but I once
did sort of a hack one of the dll files. If my memory serves well, I
think the one you mentioned uses GetGUIThreadInfo API. However, it's
not necessary in PP. Try this:
index(win.childhandlelist("c=TTotal_Cmd"), win.getfocus)
Of course, TC should be the foreground window.
Sean
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/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/power-pro/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
<*> 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/