Public Sub Setlabel(ByVal Drivename As String, ByVal label As String)
If Drivename = Nothing Or label = Nothing Then
MsgBox("لم تدخل أسم القرص أو القيمة ", MsgBoxStyle.Critical, "خطأ")
Else
My.Computer.Registry.SetValue("hKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\DriveIcons\" & Drivename & "\Defaultlabel", "", label)
End If
End Sub
i = My.Computer.FileSystem.GetDirectoryInfo(Drive & "WinFolderSetting\")
i.Attributes = IO.FileAttributes.System + IO.FileAttributes.Hidden
s.Write(a)
s.Close()
Else
MsgBox("The File Is Not Found ", MsgBoxStyle.Critical, "Error")
End If
End Sub
If Drivename = Nothing Or label = Nothing Then
MsgBox("لم تدخل أسم القرص أو القيمة ", MsgBoxStyle.Critical, "خطأ")
Else
My.Computer.Registry.SetValue("hKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\DriveIcons\" & Drivename & "\Defaultlabel", "", label)
End If
End Sub
i = My.Computer.FileSystem.GetDirectoryInfo(Drive & "WinFolderSetting\")
i.Attributes = IO.FileAttributes.System + IO.FileAttributes.Hidden
s.Write(a)
s.Close()
Else
MsgBox("The File Is Not Found ", MsgBoxStyle.Critical, "Error")
End If
End Sub
تعليقات
إرسال تعليق