i'm using VB.NET 2003 application program.
by using OpenFileDialog, we can select the file name or file path.
Code:
OpenFileDialog1.ShowDialog()
pgmPath.Text = OpenFileDialog1.FileName
by using FolderBrowserDialog, we can select the folder name or folder path.
Code:
FolderBrowserDialog1.ShowDialog()
folderPath.Text = FolderBrowserDialog1.SelectedPath
is there a way i can select shortcut. i just want to select shortcut for a folder. but when i used FolderBrowserDialog, it show only the folder list. its not showing the shortcut i have.
Quote:
|
for example: in desktop i have 4 folders, 1 EXE shortcut and 1 folder shortcut. but when i open FolderBrowserDialog it shows only 4 folders, not showing the 2 shortcuts.
|
a way i can show files that end with ".lnk" and select that shortcut. is there a way i can select shortcut's...
and by using this shell command i tried to open the EXE's.
Code:
ProgramPath = "C:\Programs\Application1.exe"
Shell(Chr(34) & ProgramPath & Chr(34), AppWinStyle.NormalFocus)
and it works fine with all the EXE to get opened.
but when i tried to open a shortcut using the same shell comment
Code:
ProgramPath = "C:\Programs\App.lnk"
Shell(Chr(34) & ProgramPath & Chr(34), AppWinStyle.NormalFocus)
error occurs... "File Not Found"
is there a way i can open the shortcut.
if anyone have any idea how to select shortcut (files that end with ".lnk") and a way i can open the shortcut, please help me. if you can provide any help, then that will be great help for me...
Thanks in advance.