Bekijk de onderstaande video om te zien hoe je onze site als een web app op je startscherm installeert.
Opmerking: Deze functie is mogelijk niet beschikbaar in sommige browsers.
Imports Microsoft.Win32
Private Shared WM_QUERYENDSESSION As Integer = &H11
Private Shared systemShutdown As Boolean = False
Protected Overrides Sub WndProc(ByRef m As Message)
If m.Msg = WM_QUERYENDSESSION Then systemShutdown = True
MyBase.WndProc(m)
End Sub
Private Sub Form1_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles MyBase.Closing
If systemShutdown Then
systemShutdown = False
If Process.GetProcessesByName("BackupEngine").Length = 0 Then
e.Cancel = False
Else
e.Cancel = True
End If
End If
End Sub
Zie het einde van dit bericht voor meer informatie over het aanroepen
van JIT-foutopsporing (Just In Time) in plaats van dit dialoogvenster.
************** Tekst van uitzondering **************
System.ArgumentOutOfRangeException: InvalidArgument=Waarde van -1 is niet geldig voor timeout.
Parameternaam: timeout
bij System.Windows.Forms.NotifyIcon.ShowBalloonTip(Int32 timeout, String tipTitle, String tipText, ToolTipIcon tipIcon)
bij System.Windows.Forms.NotifyIcon.ShowBalloonTip(Int32 timeout)
bij Backup_protector.Form1.Form1_Closing(Object sender, CancelEventArgs e) in C:\Users\Tim\documents\visual studio 2010\Projects\Backup protector\Backup protector\Form1.vb:regel 14
bij System.Windows.Forms.Form.OnClosing(CancelEventArgs e)
bij System.Windows.Forms.Form.WmClose(Message& m)
bij System.Windows.Forms.Form.WndProc(Message& m)
bij Backup_protector.Form1.WndProc(Message& m) in C:\Users\Tim\documents\visual studio 2010\Projects\Backup protector\Backup protector\Form1.vb:regel 8
bij System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
bij System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
bij System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
************** Geladen assembly's **************
mscorlib
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.239 (RTMGDR.030319-2300)
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
Backup protector
Assembly-versie: 1.0.0.0
Win32-versie: 1.0.0.0
CodeBase: file:///C:/Users/Tim/Documents/Visual%20Studio%202010/Projects/Backup%20protector/Backup%20protector/bin/Release/Backup%20protector.exe
----------------------------------------
Microsoft.VisualBasic
Assembly-versie: 10.0.0.0
Win32-versie: 10.0.30319.1 built by: RTMRel
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualBasic/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualBasic.dll
----------------------------------------
System
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.236 built by: RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Core
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.233 built by: RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Windows.Forms
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.1 built by: RTMRel
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.1 built by: RTMRel
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Configuration
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.1 (RTMRel.030319-0100)
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Xml
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.233 built by: RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Runtime.Remoting
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.1 (RTMRel.030319-0100)
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Runtime.Remoting/v4.0_4.0.0.0__b77a5c561934e089/System.Runtime.Remoting.dll
----------------------------------------
System.Windows.Forms.resources
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.235 built by: RTMGDR
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms.resources/v4.0_4.0.0.0_nl_b77a5c561934e089/System.Windows.Forms.resources.dll
----------------------------------------
mscorlib.resources
Assembly-versie: 4.0.0.0
Win32-versie: 4.0.30319.235 (RTMGDR.030319-2300)
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/mscorlib.resources/v4.0_4.0.0.0_nl_b77a5c561934e089/mscorlib.resources.dll
----------------------------------------
************** JIT-foutopsporing **************
Als u JIT-foutopsporing wilt inschakelen, moet in het configuratiebestand voor deze
toepassing of computer (machine.config) de waarde
jitDebugging in het gedeelte system.windows.forms zijn ingesteld.
De toepassing moet ook zijn gecompileerd terwijl foutopsporing
was ingeschakeld.
Bijvoorbeeld:
<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>
Wanneer JIT-foutopsporing is ingeschakeld, worden onverwerkte uitzonderingen
naar het JIT-foutopsporingsprogramma gestuurd dat op de computer is geregistreerd
en worden niet door dit dialoogvenster verwerkt.
Line 8:
Protected Overrides Sub WndProc(ByRef m As Message)
If m.Msg = WM_QUERYENDSESSION Then systemShutdown = True
MyBase.WndProc(m)
End Sub
Line 14:
NotifyIcon1.ShowBalloonTip(ShowInTaskbar)
(normaal hoort deze er te staan:
If Process.GetProcessesByName("BackupEngine").Length = 0 Then
e.Cancel = False
Else
e.Cancel = True
End If
We gebruiken essentiële cookies om deze site te laten werken, en optionele cookies om de ervaring te verbeteren.