OnlineKnowledgeRepository
OnlineKnowledgeRepository
OnlineKnowledgeRepository
Would you like to react to this message? Create an account in a few clicks or log in to continue.


For Questions and Assistance please use the proper Category.. please..
 
HomeLatest imagesSearchRegisterLog in
Welcome guys!!.. In order for you guys to post your Questions and assistance requests,, please REGISTER first.. Only members can post.. If you have requests then feel free to email ADMIN neuron or SPAMMER onatzky.. thanks!
Search
 
 

Display results as :
 
Rechercher Advanced Search
Donation box
Latest topics
» Convert signed ZD to PD
Create  shortcut of an exe or a file on desktop VB.NET EmptyThu Sep 01, 2016 7:57 pm by neuron

» Abia State Polytechnic Admission form for 2013/2014 out!
Create  shortcut of an exe or a file on desktop VB.NET EmptyTue Oct 08, 2013 9:30 am by stevejoo

» Convert ZD to SIGNED PD
Create  shortcut of an exe or a file on desktop VB.NET EmptySun Sep 08, 2013 9:22 pm by neuron

» How to Speed Up My PC
Create  shortcut of an exe or a file on desktop VB.NET EmptyTue Feb 26, 2013 9:15 am by alphysudaria143

» Hi I'm alphysudaria143
Create  shortcut of an exe or a file on desktop VB.NET EmptySun Feb 17, 2013 12:25 am by alphysudaria143

» How to Copy all the Generations of a GDG
Create  shortcut of an exe or a file on desktop VB.NET EmptyThu Oct 11, 2012 8:30 am by neuron

» Remove Duplicates in a dataset though Sort
Create  shortcut of an exe or a file on desktop VB.NET EmptyThu Oct 11, 2012 8:23 am by neuron

» how to insert data into your access database vb.net
Create  shortcut of an exe or a file on desktop VB.NET EmptyTue Aug 14, 2012 9:56 am by neuron

» how to populate combobox in vb.net during form load
Create  shortcut of an exe or a file on desktop VB.NET EmptyTue Aug 14, 2012 9:53 am by neuron

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search
Help
Please support me my registering to NEOBUX
advertisements
Create  shortcut of an exe or a file on desktop VB.NET Banner3
Affiliates
free forum
 



 

 Create shortcut of an exe or a file on desktop VB.NET

Go down 
AuthorMessage
neuron
Administrator
Administrator
neuron


Posts : 38
Join date : 2009-08-06

Create  shortcut of an exe or a file on desktop VB.NET Empty
PostSubject: Create shortcut of an exe or a file on desktop VB.NET   Create  shortcut of an exe or a file on desktop VB.NET EmptyThu Aug 06, 2009 11:49 pm

Here's how to create a shortcut using your VB.NET program

Code:

Public Sub create_shortcut()
        Dim wsh As Object = CreateObject("WScript.Shell")

        wsh = CreateObject("WScript.Shell")

        Dim MyShortcut, DesktopPath

        ' Read desktop path using WshSpecialFolders object

        DesktopPath = wsh.SpecialFolders("Desktop")

        ' Create a shortcut object on the desktop

        MyShortcut = wsh.CreateShortcut(DesktopPath & "\XXXXX.lnk")

        ' Set shortcut object properties and save it

        MyShortcut.TargetPath = wsh.ExpandEnvironmentStrings("C:\XXX.TXT")

        MyShortcut.WorkingDirectory = wsh.ExpandEnvironmentStrings("C:\")

        MyShortcut.WindowStyle = 4

        'Use this next line to assign a icon other then the default icon for the exe

        MyShortcut.IconLocation = "%SystemRoot%\system32\SHELL32.dll,44"

        'Save the shortcut

        MyShortcut.Save()

    End Sub

Back to top Go down
https://myonlinekr.forumotion.com
 
Create shortcut of an exe or a file on desktop VB.NET
Back to top 
Page 1 of 1
 Similar topics
-
» How to Check and create a folder in VB.NET
» USing the File Browser in VB.net
» Extract Part 1 of a RAR FILE

Permissions in this forum:You cannot reply to topics in this forum
OnlineKnowledgeRepository :: All About PC :: Programming :: VB.NET-
Jump to: