Page 1 of 2 12 LastLast
Results 1 to 15 of 18
  1. #1
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic

    Creating Shortcuts [.lnk] on Desktop

    hi mpgh, i want a help.

    I want to know how to create a link of my program on the desktop.

    -------------------------------------------------------------------------------------

    I will know how to put in a listbox all the .dll files in a folder (I choose the folder and in the listbox must be there all the files with a specified format, like .dll or .txt)

    Press Rep if you like my programs and my helps


  2. #2
    'Bruno's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Portugal
    Posts
    2,883
    Reputation
    290
    Thanks
    1,036
    My Mood
    Busy
    I cant really understand what you say, you mean, a shortcut? :s
    Light travels faster than sound. That's why most people seem bright until you hear them speak.

  3. #3
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    Yes, when you do a right click on the desktop, under "Folder" there is "Link", in english it's "Shortcut"? xD

    Press Rep if you like my programs and my helps


  4. #4
    'Bruno's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Portugal
    Posts
    2,883
    Reputation
    290
    Thanks
    1,036
    My Mood
    Busy
    Yes, right click your app and create a shortcut of it o.O
    Light travels faster than sound. That's why most people seem bright until you hear them speak.

  5. #5
    Hassan's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    System.Threading.Tasks
    Posts
    4,764
    Reputation
    495
    Thanks
    2,133
    My Mood
    Dead
    Quote Originally Posted by Brinuz View Post
    Yes, right click your app and create a shortcut of it o.O
    Lol, I think he wants to do this using VB though!


    ---------- Post added at 04:59 AM ---------- Previous post was at 04:56 AM ----------

    Quote Originally Posted by __]H[elroos View Post
    hi mpgh, i want a help.

    I want to know how to create a link of my program on the desktop.

    -------------------------------------------------------------------------------------

    I will know how to put in a listbox all the .dll files in a folder (I choose the folder and in the listbox must be there all the files with a specified format, like .dll or .txt)
    Couple of links that may be of help to you:

    Create a Desktop shortcut
    Creating Shell Links (Shortcuts) in .NET Programs Using WSH - CodeProject
    winforms - how to create shortcut on desktop in vb.net without installer - Stack Overflow

  6. #6
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    ç_ç i dont understand these tuts.

    I try the 3rd link.

    ---------- Post added at 10:56 AM ---------- Previous post was at 10:48 AM ----------

    ç_ç Too many errors.
    I think it's a short code, like "Shortcut.Creatr(C:\Program.exe , my.computer.filesystem.specialdiectories.desktop & \Shortcut.lnk)" xD

    Can anyone try it (Not my example xD) and posta working code?

    Press Rep if you like my programs and my helps


  7. #7
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    Nothing?? Help me pls ç_ç

    Press Rep if you like my programs and my helps


  8. #8
    Blubb1337's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Germany
    Posts
    5,915
    Reputation
    161
    Thanks
    3,108
    Quote Originally Posted by __]H[elroos View Post
    ç_ç i dont understand these tuts.

    I try the 3rd link.

    ---------- Post added at 10:56 AM ---------- Previous post was at 10:48 AM ----------

    ç_ç Too many errors.
    I think it's a short code, like "Shortcut.Creatr(C:\Program.exe , my.computer.filesystem.specialdiectories.desktop & \Shortcut.lnk)" xD

    Can anyone try it (Not my example xD) and posta working code?
    Did you even add a reference to the Windows Script Host Object Model?



  9. #9
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    Yes, but when i do the debug there isnt ant shortcut on the desktop D:

    Press Rep if you like my programs and my helps


  10. #10
    Blubb1337's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Germany
    Posts
    5,915
    Reputation
    161
    Thanks
    3,108
    Quote Originally Posted by __]H[elroos View Post
    Yes, but when i do the debug there isnt ant shortcut on the desktop D:
    You are probably not using the parameters right. Show me the code you are using.



  11. #11
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    For now no one
    because no one of these posted by hassan are working for me :|

    Press Rep if you like my programs and my helps


  12. #12
    Hassan's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    System.Threading.Tasks
    Posts
    4,764
    Reputation
    495
    Thanks
    2,133
    My Mood
    Dead
    Quote Originally Posted by __]H[elroos View Post
    For now no one
    because no one of these posted by hassan are working for me :|
    It is not my problem that you are just copying and pasting the code with out using any of your sense(s). I can't spoon feed you. I gave you the links. Read them carefully.

  13. #13
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    I dont do only C&P.
    I've read these correctly and writed correctly.
    No one error but when i use this code there isnt any shortcut.

    Press Rep if you like my programs and my helps


  14. #14
    Hassan's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    System.Threading.Tasks
    Posts
    4,764
    Reputation
    495
    Thanks
    2,133
    My Mood
    Dead
    Quote Originally Posted by __]H[elroos View Post
    I dont do only C&P.
    I've read these correctly and writed correctly.
    No one error but when i use this code there isnt any shortcut.
    Post your code then, as Blubb said.

  15. #15
    __]H[elroos's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Location
    Rome
    Posts
    301
    Reputation
    44
    Thanks
    842
    My Mood
    Angelic
    Ok i'm using this code:

    Imports IWshRuntimeLibrary
    Public Class Form1

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    Dim WshShell As WshShellClass = New WshShellClass
    Dim MyShortcut As IWshRuntimeLibrary.IWshShortcut
    Dim DesktopFolder As String = Environment.GetFolderPath(Environment.SpecialFolde r.DesktopDirectory)
    MyShortcut = CType(WshShell.CreateShortcut(DesktopFolder & "\MyShortcutName.lnk"), IWshRuntimeLibrary.IWshShortcut)
    MyShortcut.TargetPath = Application.StartupPath & "\YourApp.exe" 'Specify target app full path
    MyShortcut.Save()
    End Sub
    End Class

    Error:

    Errore 1 Impossibile incorporare il tipo di interoperabilità 'WshShellClass'. In alternativa, utilizzare l'interfaccia applicabile. C:\Users\****\AppData\Local\Temporary Projects\WindowsApplication1\Form1.vb 5 41 WindowsApplication1

    Press Rep if you like my programs and my helps


Page 1 of 2 12 LastLast

Similar Threads

  1. [Tutorial] Creating a shortcut to the folder AppData
    By Flexus in forum Minecraft Tutorials
    Replies: 12
    Last Post: 09-01-2011, 08:03 AM
  2. How to make a ShutDown ShortCut at your Desktop
    By Silk[H4x] in forum Programming Tutorials
    Replies: 3
    Last Post: 08-16-2008, 07:40 AM
  3. Replies: 13
    Last Post: 02-09-2006, 10:25 PM
  4. how to create speedhacks?
    By LiLLeO in forum General Game Hacking
    Replies: 5
    Last Post: 01-28-2006, 08:52 AM
  5. Creating A GunzRunnable
    By CrazyDeath in forum Game Hacking Tutorials
    Replies: 7
    Last Post: 01-01-2006, 11:20 PM