AutoHotkey Community

It is currently May 27th, 2012, 5:07 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 167 posts ]  Go to page Previous  1 ... 5, 6, 7, 8, 9, 10, 11, 12  Next
Author Message
 Post subject:
PostPosted: October 12th, 2005, 3:56 am 
Offline

Joined: November 28th, 2004, 10:26 pm
Posts: 58
Hi Everyone:
A new version of the script is in the first post of this thread.

Here's the changes:
Oct 11/05
- fixed bug that read in the enviroment path variable when no valid path was found in window title or clipboard.
- added support for .pif files
- added support for ordering menu items (.lnk files only) and adding seperator lines, thru the comment field of the .lnk files
- added more error checking


dmiranda wrote:
sometimes when attemtpting to switch within to a subfolder's shortctu item, I am redirected to the favorites folder, instead.

I could not reproduce that behavior so maybe it's fixed with this update.

The ordering of the menu items and seperator lines is something that people wanted from savage's original script. This is a partial solution, since it only works with one kind of shortcut file (.lnk). It's completely optional. If you want to use it just add "menu=(integer to indicate menu position)" to the comment field of the shortcut file. It won't work on .url or .pif shortcuts. FileGetShortcut does not read those types.
If you want a seperator line just add "blank" after the integer in the comment.
If a shortcut does not have any of this in it's comment it will be added to the bottom of the menu as normal.

I think this is a good feature to have in the script, but now that it's done I don't think this way of doing it is the best. I think a better way would be a seperate .ini file stored in the same folder as the main script that specifies the order of the menu items would be better. All kinds of shortcuts and even the submenus could be ordered in any way. But I think this would require a GUI to be used when adding or editing the menus in order to keep the .ini file up to date. I started working at it but it seems it may get pretty complicated handling the submenus. So I don't know if I'll ever get that done.

_________________
ChrisM


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 12th, 2005, 5:14 am 
Unbelieveably nice. Cheers!

Still, I have now the following (extremelly minor) issue: duplicated shortcut names in different forlders point to the same directory. To replicate this:

create two folders A and B;
create two shortcut to diferent directories, one in A and the other in B;
give the shortcuts the same name.

In my system this results on both shortcuts pointing to the same directory.


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: October 12th, 2005, 2:19 pm 
Offline

Joined: August 15th, 2005, 2:57 pm
Posts: 57
I still get the following message:

"The folder \\My Documents\Favorites could not be created.
Cannot save Favorites links."

In my case %HOMEPATH% translates to a "\" and not any path. Therefore in the error message above you get a "\\" before My Documents.

I still change my default path to c:\favs and the script works fine.

As the other comments state, This IS the most used script I have. Thanks for sharing it.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 13th, 2005, 6:11 am 
Offline

Joined: November 28th, 2004, 10:26 pm
Posts: 58
Hi Everyone:
Another new version of the script is in the first post of this thread.

Here's the changes:
Oct 13/05
- fixed bug that didn't handle identical named shortcuts in different folders properly
- added better error checking for dynamic variable names that are too long

Anonymous wrote:
duplicated shortcut names in different forlders point to the same directory.

It's fixed now. Thanks for pointing it out to me. Turned out to be some leftover logic from the pre-submenu days when I simply relied on the fact that every shortcut in the base folder would be a unique name.

aarondellis wrote:
In my case %HOMEPATH% translates to a "" and not any path. Therefore in the error message above you get a "" before My Documents.

Since someone may decide to use another enviroment variable or hard code the path I don't think I should add any error checking for that beyond the error you are already getting. It's up to the user to be sure the 'f_shortcuts_folder' variable is a valid absolute path. I'll add a line to that error message to clarify that.

_________________
ChrisM


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 14th, 2005, 3:10 pm 
Offline

Joined: August 15th, 2005, 2:57 pm
Posts: 57
You're right! I had to stop and think where the %homepath% variable was getting set. When connected to the network at work evidently that variable is being set to "\". That is why I was getting the error. When not connected to our network the variable is how you intended it to be and the script works well.

I just hardcode the path and I have no problems.

A thought! What if the script instead of stopping with the error I was receiving asks you where you would like the shortcut folder to be located. That would require INI files to keep up with the location but would keep your script from failing.

Even if you don't incorporate that it is still a great script. Thanks again!


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 17th, 2005, 10:20 pm 
Offline

Joined: October 5th, 2005, 12:40 pm
Posts: 19
Location: china
would you add its icon to each menu item ?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 18th, 2005, 12:40 am 
vital wrote:
would you add its icon to each meu item ?
I hope not, that would slow the script down.


Report this post
Top
  
Reply with quote  
 Post subject: Hyperlinks
PostPosted: October 26th, 2005, 7:41 pm 
Offline

Joined: August 19th, 2005, 4:36 pm
Posts: 14
Location: Germany
Great script, I have integrated it in my multi-porpose utility.

A "Hyperlink" functionality would be nice, so a link to the desktop
the "original" favorites folder and the Quicklauch could be established.

Adding a special name ? shortcut, e.g. HYPER_Quicklaunch pointing to "%APPDATA%\Microsoft\Internet Explorer\Quick Launch" should be presented as a submenu ( like a folder) and showing the original shortcuts.

And how about "my subfolder\first shortcut" entered in the "add folder to favorites" creating a "my subfolder" subfolder and the "first shortcut" in this subfolder ?

Keep on autohotkeying

Hans Peter


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 27th, 2005, 3:45 pm 
Offline

Joined: July 2nd, 2004, 11:53 pm
Posts: 207
If you're using ntfs you could hard link the quicklink folder into your favorites folder.

_________________
<enormous animated gif>


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: January 7th, 2006, 12:51 pm 
just started using the app, and this is a great script!

A little thing I've added, is a variable pointing to my file-manager (and parameters) of choice, for the 'f_EditFavorites' function. Sorry that I didn't bother reading the whole thread for something similar, but if it hasn't been suggested before, then consider it a request. I suppose I'm not the only one who prefers other filemanagers than explorer ;)

again, though, fabulous script!


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: February 1st, 2006, 1:40 pm 
Offline

Joined: January 31st, 2006, 2:11 pm
Posts: 28
I have been looking for a shell extension to have a list if commonly used folders available in the open / save dialogs and came across AutoHotKey.

All the help I have read seem to be geared towards creating your own scripts. I just want to run one to do the above - this Favorite Folders script

After installing AutoHotKey I replaced AutoHotkey.ini with the above script and restarted wiht AutoHotKey running. But when I am in a file open dialog the middle button does nothing, it's mean to access a favourite list I believe.

Am I doing something wrong?

Thanks, Tom.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: February 2nd, 2006, 2:52 am 
Offline

Joined: March 2nd, 2004, 3:36 pm
Posts: 10720
Note that mouse button hotkeys are not supported on Windows 9x. If that's the problem, you could try substituting a keyboard hotkey.

Otherwise, you might try running the script as a separate .ahk file. If the script in this topic gives you any trouble, perhaps your mouse's middle button is controlled by your mouse driver. To test your mouse, you could try making a short script called test.ahk, containing one line:

MButton::MsgBox You pressed the middle mouse button.

Run it and press your middle mouse button to see if a MsgBox window appears.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: February 2nd, 2006, 4:25 am 
Offline

Joined: November 28th, 2004, 10:26 pm
Posts: 58
My apologies boardtc.
I see that the first line of the script description was not updated properly and mislead you. It has now been changed to read:
Code:
; When you hold the control key and click the middle mouse button while certain
; types of windows are active, this script displays a menu of your favorite
; shortcuts.

Further down the config section of the script you will see two settings:
Code:
; CONFIG: CHOOSE WHEN TO SHOW THE MENU
...
f_AlwaysShowMenu = y

; CONFIG: CHOOSE YOUR HOTKEYS
...
f_Hotkey1 = ^MButton ; Control+MiddleButton

If you do want to use only the middle button in only open / save dialogs then you may want to make these changes:
Code:
f_AlwaysShowMenu = n

and:
Code:
f_Hotkey1 = ~MButton

_________________
ChrisM


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: February 2nd, 2006, 11:56 am 
Offline

Joined: January 31st, 2006, 2:11 pm
Posts: 28
Thanks for this.

I tried the new changes and after rebooting Ctrl+middle btn in the open dialog (standard) for my text editor (editpad) did not work. I also tried chnaging the script as suggested to just work for the middle btn and that did not work either.

I must be doing something wrong. I am running xp pro sp 2.

I see in the help about the reload command.
^!r::Reload ; Assign a hotkey to restart the script.

Does this mean if I hold down ctrl and caps+1 (!) r it will reload? Ihave been
rebooting to reload each time.

Thanks for the hand holding :-)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: February 4th, 2006, 3:19 pm 
Offline

Joined: March 2nd, 2004, 3:36 pm
Posts: 10720
You don't have to reboot to reload. The hotkey you mentioned above (^!r::Reload) will do that for you -- or you can select Reload from the tray menu.

As for the rest of your questions, I'm not an expert on this script so don't have any other quick advice.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 167 posts ]  Go to page Previous  1 ... 5, 6, 7, 8, 9, 10, 11, 12  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: Stigg and 12 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group