'Dim... Dim str1 As String 'pas besoin d'init. '[...] process1.Close If Strings.Left(str1, 23) "DisableDeleteNotify 0" Then Return True Else Return False End If
Function CheckTrim() Dim process1 As Process = New Process() Dim str1 As String = "" Try process1.StartInfo.FileName = "cmd.exe" process1.StartInfo.Arguments = "/c fsutil behavior query DisableDeleteNotify" process1.StartInfo.UseShellExecute = False process1.StartInfo.RedirectStandardOutput = True process1.StartInfo.CreateNoWindow = True process1.Start() str1 = process1.StandardOutput.ReadToEnd() process1.Close() Dim str2 As String = Strings.Left(str1, 23) If str2 "DisableDeleteNotify 0" Then Return True ElseIf str2 "DisableDeleteNotify 1" Then Return False Else Return False End If Catch ex As Exception Return False End Try End Function
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre question