Guest Garen Posted March 4, 2004 Share Posted March 4, 2004 Hello I can't get a file path, for example using WinGetActiveStats I can get the Title, Width, positoin of active file, but not PATH (C:\\??????????\\???????\\) Please help Link to comment Share on other sites More sharing options...
Developers Jos Posted March 4, 2004 Developers Share Posted March 4, 2004 HelloI can't get a file path, for example using WinGetActiveStats I can get the Title, Width, positoin of active file, but not PATH (C:\\??????????\\???????\\)Please helpWinGetActiveStats retrieves information about the active window not about the active program that generates this window.Maybe you can explain what you would like to accomplish ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Guest Garen Posted March 5, 2004 Share Posted March 5, 2004 Ok, may be my question were not so correct asked So, I will ask it in example You are right, about the WinGetActiveStatus that it take the information about the active window, I know this, So I want find the way which can detect the full path of this active window For me it is need for detecting opened Folder's path And I have ones more question. Is there any way like the command "while" ? example: While, <InputBox, variable, title, massage>, <do something> It is need for blocking some an other action during the Input I try to put password on files or folders which I want to protect using command WinWaitAstive, WinHide, when any want to open my folder there appear the dialog with question of password, but when user try to open the folder again ignoring the question script don't work (It still stay at the old command of INputing the password) sorry for my bad english if any thing I have written not correctly Link to comment Share on other sites More sharing options...
Beastmaster Posted March 5, 2004 Share Posted March 5, 2004 There's an option which you should enable: Run Explorer\Tools\Folder Options\View\ --> Display the full Path in Title Bar Now you should be able to read the path from the windows title bar !? What I've understand from your 2nd request (I'm sorry too my english isn't much better) ... You want to protect files/folders not to be accessed without permission? On the other hand - if the login was done once successfull, you don't want to be asked again? Can you provide some code. Don't be shy ... Link to comment Share on other sites More sharing options...
Guest Garen Posted March 10, 2004 Share Posted March 10, 2004 it is very simple way, I know I want show the problem width this line: InputBox, password, Entering Password, Please - Enter Your Password!, hide If user ignore this dialog and try open the folred, the script dose not work this time and is there any an other way to get full path of opend folder ? start: WinWaitActive, MyFolderName WinHide, MyFolderName start2: InputBox, password, Entering Password, Please - Enter Your Password!, hide IfEqual, password, mypassword, Goto, open WinClose, MyFlderName MsgBox, 49, ERROR, wrong password, If you Want try again enter OK IfMsgBox, OK, Goto, start2 Goto, start open: WinShow, MyFolderName Link to comment Share on other sites More sharing options...
Guest rathore Posted March 26, 2004 Share Posted March 26, 2004 let's make somethings sure first. I'm assuming these, tell me if you don't agree: -you want any attempt to open a specific folder (let's call it MyFolderName) to be blocked unless authenticated. -if there are folders within MyFolderName then you WILL HAVE TO enable "Display the full Path in Title Bar" as beastmaster said. -if there are no folders inside it then its okay. now try this: DetectHiddenText, on SetBatchLines, 200 SetTitleMatchMode, 2 SetWinDelay, 1 start: IfWinExist, MyFolderName,, goto, start2 sleep,1000 goto, start start2: InputBox, password, Entering Password, Please - Enter Your Password!, hide IfEqual, password, mypassword, Goto, open WinClose, MyFolderName MsgBox, 49, ERROR, wrong password, If you Want try again enter OK IfMsgBox, OK, Goto, start2 Goto, start open: WinShow, MyFolderName [ADLIB] MyFolderName,,WinHide, MyFolderName this script works alright, but if someone can then plz shed light on why does it take some time (or changing the active window) before the inputbox is shown. Link to comment Share on other sites More sharing options...
Recommended Posts