Hi All,

I want to create a shortcut on my desktop of an OragnizationUnit with a
logonScript.
I try to use the follow code:


'**********
set WshShell = WScript.CreateObject("WScript.Shell")
strDesktop = WshShell.SpecialFolders("Desktop")
set oShellLink = WshShell.CreateShortcut(strDesktop &
"\SharedFolder.lnk")
oShellLink.TargetPath = "ntds://myDomain.it/myOU"
oShellLink.relativePath = "ntds://myDomain.it/myOU"
oShellLink.Description = "Shortcut to SharedoFolder"
oShellLink.WorkingDirectory = strDesktop
oShellLink.Save
'**********

But it does not create a valid shortcut.
Do u have an idea why it does not work??
The only way i find to create the shortcut to the OU is to drag and drop the
OU on my desktop, but I must to automate it!!!

Please Help me!

Sergio Marchi

Re: How to create a NTDS shortcut on myDesktop by name

name
Mon Jul 21 03:35:18 CDT 2003

You can create any protocol you want in windows.

No one will accept it across a network without consensus.

Guess that is why "military computers"

in general are no the considered a bread winner.




"sergio marchi" <sergio.marchi@email.it> wrote in message
news:ecvPkEiRDHA.1324@TK2MSFTNGP11.phx.gbl...
> Hi All,
>
> I want to create a shortcut on my desktop of an OragnizationUnit with a
> logonScript.
> I try to use the follow code:
>
>
> '**********
> set WshShell = WScript.CreateObject("WScript.Shell")
> strDesktop = WshShell.SpecialFolders("Desktop")
> set oShellLink = WshShell.CreateShortcut(strDesktop &
> "\SharedFolder.lnk")
> oShellLink.TargetPath = "ntds://myDomain.it/myOU"
> oShellLink.relativePath = "ntds://myDomain.it/myOU"
> oShellLink.Description = "Shortcut to SharedoFolder"
> oShellLink.WorkingDirectory = strDesktop
> oShellLink.Save
> '**********
>
> But it does not create a valid shortcut.
> Do u have an idea why it does not work??
> The only way i find to create the shortcut to the OU is to drag and drop
the
> OU on my desktop, but I must to automate it!!!
>
> Please Help me!
>
> Sergio Marchi
>
>
>
>