VERSION 5.00 Begin VB.Form frmVolgnummer BorderStyle = 3 'Fixed Dialog Caption = "Volgnummer" ClientHeight = 2625 ClientLeft = 45 ClientTop = 435 ClientWidth = 4680 ClipControls = 0 'False ControlBox = 0 'False LinkTopic = "Form1" ScaleHeight = 2625 ScaleWidth = 4680 ShowInTaskbar = 0 'False StartUpPosition = 2 'CenterScreen Begin VB.CommandButton cmdStop Caption = "Stop" Height = 495 Left = 120 TabIndex = 5 Top = 1920 Width = 2175 End Begin VB.CommandButton cmdOk Caption = "OK >>" Height = 495 Left = 2400 TabIndex = 4 Top = 1920 Width = 2175 End Begin VB.Frame Frame1 Height = 1575 Left = 120 TabIndex = 0 Top = 120 Width = 4455 Begin VB.TextBox txtVolgnummer Alignment = 1 'Right Justify Height = 375 Left = 2400 TabIndex = 3 Text = "1" Top = 840 Width = 1215 End Begin VB.Label Label2 Caption = "Geef het unieke volgnummer:" Height = 375 Left = 120 TabIndex = 2 Top = 900 Width = 2295 End Begin VB.Label Label1 Caption = "In MGeoBase krijgt elk profiel een uniek nummer. Dit nummer is nodig voor de scenarioselectie. " Height = 495 Left = 120 TabIndex = 1 Top = 240 Width = 4215 End End End Attribute VB_Name = "frmVolgnummer" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Private Sub cmdOk_Click() 'Declareer locale variabelen Dim i 'set error trap On Error GoTo errorHandler 'Lees het volgnummer in volgNummer = txtVolgnummer.Text 'Sluit het huidige scherm en open het scherm opslaan Unload frmVolgnummer frmOpslaan.Show 'Voorkom dat de errorHandler onnodig wordt uitgevoerd Exit Sub 'Trap errorHandler: txtVolgnummer.Text = 1 'Toon waarschuwing i = MsgBox("Volgnummer is geen integer, geef een correct nummer op", vbCritical, "Fout!") End Sub Private Sub cmdStop_Click() 'Declareer locale variabelen Dim i i = MsgBox("Weet u zeker dat u wilt stoppen? Wijzigingen worden niet opgeslagen!", vbYesNo, "Let op!") If i = vbYes Then 'Stop het programma End End If End Sub