You are here

@Ryan McCue, help with RDTools

11 posts / 0 new
Last post
wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
@Ryan McCue, help with RDTools

I seem to be having a permissions or something issue with RDTools on 32-bit Vista Ultimate SP1. RDTools seems to create the SendTo shortcuts just fine, but it cannot remove them. This is strange. I have to investigate a little further what's going on and if it is a problem with permissions or not.

Some strange behavior in general though, if I type 'sendto' in the run box in Vista, I get an access denied error. But I can navigate to the directory and delete what I want just fine. I'm sure this is all related.

Any ideas what's going on? Just a strange change in Vista maybe and RDTools can't work on it?

Steve Lamerton
Steve Lamerton's picture
Offline
Last seen: 11 years 2 months ago
Developer
Joined: 2005-12-10 15:22
I

think that I can tell you. The reason is that when you head to the sendto folder in Explorer you are actually being sent down a symlink to some other location, although you can´t tell. However it seems that the run box doesn´t support the symlinks. The way to solve this is do to a search of the system to find out where the files in the SendTo folder are and set the program up to use that location.

Tim Clark
Tim Clark's picture
Offline
Last seen: 13 years 7 months ago
Joined: 2006-06-18 13:55
SendTo

"search of the system to find out where the files in the SendTo folder are"

In XP its this:
C:\Documents and Settings\tclark\SendTo

I assume in Vista it's something like this:
C:\Users\tclark\SendTo

Tim

Things have got to get better, they can't get worse, or can they?

Steve Lamerton
Steve Lamerton's picture
Offline
Last seen: 11 years 2 months ago
Developer
Joined: 2005-12-10 15:22
Thanks

Tim, I would have searched myself, but as I was posting from a Nokia n800 not only was I on the wrong OS (Linux), but the wrong architecture too (ARM) Smile

wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
Well, you would assume that,

Well, you would assume that, and that's where Vista would kick us in the nuts.

C:\Users\tclark\SendTo

is a JUNCTION with the hidden and system attributes that actually points to -

C:\Users\tclark\AppData\Roaming\Microsoft\Windows\SendTo

I think the junction is the problem. Why it doesn't work from the run box is beyond me, as well why you can add files, but not delete them. I checked Ryan's source, and it expands variables to

C:\Users\tclark\SendTo

I'm not sure what to do about this yet. Is Ryan around? I'd like to get his thoughts.

rab040ma
Offline
Last seen: 4 months 4 weeks ago
Joined: 2007-08-27 13:35
Ewww

The Start Menu is there too.

It looks like

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders

or the User Shell Folders key both point to the right place, so that might be a way to handle it, rather than just hunting for it. I'd guess that key would work on most other versions too.

MC

wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
There's a funny message at

There's a funny message at the top of that branch that says

!Do not use this registry key

Use the SHGetFolderPath or SHGetKnownFolderPath function instead

Not sure what that means exactly.

wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
Ok, so why would that allow

Ok, so why would that allow RDTools to create the shortcuts, but not remove them?

I'll have to look at Ryan's source and see what I can see.

wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
Fixed

Ok, fixed it. I tested on Vista last night using the correct SendTo path, and RDTools works correctly.

So I thought I'd do one better and actually figure out how to use the SHGetFolderPath function. Here's the code for AutoIt3 (what RDTools is written in) -

$hwndOwner = ""
;$nfolder="CSIDL_SENDTO" using integer value of 9 (0x0009) below
$nfolder = 0x0009
$hToken = ""
;$dwFlags="SHGFP_TYPE_CURRENT"
$dwFlags = 0
$pszPath = ""
$sendto = DllCall("shell32.dll", "int", "SHGetFolderPath", _
				"hwnd", $hwndOwner, _
				"int", $nfolder, _
				"ptr", $hToken, _
				"dword", $dwFlags, _
				"str", $pszPath _
				)

I'm going to post an updated binary and source for those that want it.

Ryan McCue
Ryan McCue's picture
Offline
Last seen: 15 years 1 month ago
Joined: 2006-01-06 21:27
Note:

I didn't write it, I only host it.

"If you're not part of the solution, you're part of the precipitate."

wraithdu
Offline
Last seen: 11 years 5 months ago
Developer
Joined: 2007-06-27 20:22
Yeah, I finally figured that

Yeah, I finally figured that out. Feel free to grab the updated EXE and update your hosted version.

Log in or register to post comments