PowerBuilder Function Create Shortcut gf_create_shortcut
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 |
// Function Name : gf_create_shortcut // Argument Name : (None) // Return Type : (None) OleObject ws OleObject loo_shortcut String ls_Desktop ws = Create OleObject ws.ConnectToNewObject(" WScript.Shell") ls_Desktop = ws.SpecialFolders("Desktop") // other "specialfolder" of interest // AllUsersDesktop // AllUsersStartMenu // AllUsersPrograms // AllUsersStartup // Desktop // Favorites // MyDocuments // Programs // Recent // SendTo // StartMenu // Startup loo_shortcut = ws.CreateShortcut(ls_Desktop + "\programmingmethodsit.lnk") loo_shortcut.TargetPath = "https://pblib.com" loo_shortcut.WorkingDirectory = ls_Desktop loo_shortcut.WindowStyle = 1 /* 1 Activates and displays a window. If the window is minimized or maximized, the system restores it to its original size and position. 3 Activates the window and displays it as a maximized window. 7 Minimizes the window and activates the next top-level window. */ loo_shortcut.IconLocation = ws.ExpandEnvironmentStrings("%WINDIR%\SYSTEM\url.dll,0") |
Good Luck!
Subscribe
Login
0 Comments
Oldest