Runt-time error 0
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 9 of 9

Thread: Runt-time error 0

Threaded View

  1. #1
    Join Date
    Feb 2003
    Location
    Holland
    Posts
    121

    Runt-time error 0

    When i start the .exe and click the first time the listview, it starts the calculation for that period and al works fine.
    Direct after ending the calculation i chose an other company and click the listview again. Then i get the error.
    Sorry, i do not know how to post the code on the right way. I found out!
    Thans for your help.

    Herman

    Code:
    Private Sub LvTijdvakken_Click()
       ' On Error GoTo Foutje
       'On Error Resume Next
        
        LvTijdvakken.HideSelection = False
        If Val(LvTijdvakken.SelectedItem.Text) <= 0 Then
            Exit Sub
        End If
        Z = LvTijdvakken.SelectedItem.Index
        If Z < 1 Or Z > LvTijdvakken.ListItems.Count Then Exit Sub
        If GetSetting("HataSal", "LoonRun", "Vakantiegeld") > "" Then
           ' 'debug.print GetSetting("HataSal", "LoonRun", "Vakantiegeld")
            DeleteSetting "HataSal", "LoonRun", "Vakantiegeld"
        End If
        frmLoonberekeningStart.txtLoonTijdVak(0) = LvTijdvakken.SelectedItem.Text
        frmLoonberekeningStart.txtLoonTijdVak(1) = LvTijdvakken.SelectedItem.SubItems(1)
        frmLoonberekeningStart.txtLoonTijdVak(2) = LvTijdvakken.SelectedItem.SubItems(2)
        VulWerknemersListBox
        Bewerking = "LvTijdvakken_Click 01 "
        
        frmLoonberekeningStart.cmdTijdvakAkkoord.Enabled = True
        frmLoonberekeningStart.cmdTijdvakVerijderen.Enabled = True
        Temp1 = Trim(Left(frmLoonberekeningStart.txtLoonTijdVak(0).Text, 2))
        LoonBestand = WgBestandsPad & "\lonen" & Temp1 & "." & Trim(SalarisJaar)
        If FileExist(LoonBestand) Then
            frmLoonberekeningStart.cmdTijdvakAkkoord.Caption = "Bewerken"
            frmLoonberekeningStart.FrameBerekenenWerknemers.Visible = False
            frmLoonberekeningStart.Label1.Visible = True
        Else
            frmLoonberekeningStart.cmdTijdvakAkkoord.Caption = "Aanmaken"
            frmLoonberekeningStart.FrameBerekenenWerknemers.Visible = True
            frmLoonberekeningStart.Label1.Visible = False
        End If
    
        If Val(frmLoonberekeningStart.txtLoonTijdVak(0).Text) = Val(Wg.VakGeldBetalen1) Then
            If Not IsDate(LvTijdvakken.SelectedItem.SubItems(4)) Then
                frmVakantiegeld.Show
                frmLoonberekeningStart.Enabled = False
            End If
        End If
    
        If Val(frmLoonberekeningStart.txtLoonTijdVak(0).Text) = Val(Wg.VakGeldBetalen2) Then
            If Not IsDate(LvTijdvakken.SelectedItem.SubItems(4)) Then
                frmVakantiegeld.Show
                frmLoonberekeningStart.Enabled = False
            End If
        End If
        If WekenControle = False Then
            Unload frmLoonberekeningStart
            Set frmLoonberekeningStart = Nothing
            OpenMenu
        End If
    Exit Sub
    Foutje:
    Foutmeldingen
    
    End Sub
    Last edited by HermanTabbert; January 23rd, 2014 at 04:23 AM.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center