Microsoft Office Excel ® Kod Kılavuzu

Microsoft Office Excel® Code Guide

10 Mayıs 2007 Perşembe

Create Short Cut Path On Start Button



'Module1

Option Explicit
Dim Yol As String '
Path
Dim Simge As Object
'Icon
Dim SimgeYol As Object
'IconPath
Dim KısaYol As String
'ShortCutPath
Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Sub KısaYolYarat()
'ShortCutPath Create

On Error Resume Next
Set Simge = VBA.CreateObject("Wscript.Shell")
Yol = Simge.SpecialFolders("Programs")
VBA.MkDir Yol & "\Pbid"
KısaYol = Yol & "\Pbid" & "\" & "Pbid.lnk"
Set SimgeYol = Simge.CreateShortcut(KısaYol)
With SimgeYol
.TargetPath = "C:\Documents and Settings\PC\Desktop\BLOGSPOT\KısaYolYarat.xls"
.Description = "Pbid ® ShortCut Path of KısaYolYarat.xls"
.IconLocation = "C:\Documents and Settings\PC\Desktop\BLOGSPOT\Örnekİkonlar\PBİD.ico"
.RelativePath = "C:\Pbid"
.WorkingDirectory = "C:\Documents and Settings\PC\Desktop\BLOGSPOT"
.Hotkey = "Ctrl+Alt+p"
.Save
End With
Set Simge = Nothing
Call BaşlatAç
End Sub
Sub BaşlatAç()
'Open Start Bar

On Error Resume Next
Call keybd_event(&H11, 0, 0, 0)
Call keybd_event(&H1B, 0, 0, 0)
Call keybd_event(&H1B, 0, &H2, 0)
Call keybd_event(&H11, 0, &H2, 0)
End Sub 

Hiç yorum yok:

Blog Arşivi

Bu gadget'ta bir hata oluştu

Bu Blogda Ara

Contributor

Contributor
Mustafa ULUSARAÇ İstanbul, TÜRKİYE
free counters
T. C. Central Bank Indicative Exchange Rates
Currency Exchange Rate Widget,Currency Converter Widget
Borsa İstanbul