Results 1 to 6 of 6

System.FormatException: Input string was not in a correct format

Threaded View

  1. #1
    Registered User
    Join Date
    04-01-2012
    Location
    Europe
    MS-Off Ver
    Excel 2010
    Posts
    6

    System.FormatException: Input string was not in a correct format

    Hello

    I have a problem with this script. Whats is wrong with it?

    Function OK()
    
    
    Workbooks.Open Filename:="C:\Rapport_2012-04-04.csv"
    
    
    Sheets("Rapport").Activate
        Dim what3 As String = "OK"
          Do
          Set r1 = ActiveSheet.UsedRange.Find(what3)
            If r1 Is Nothing Then
                Exit Do
              Else
                Rows(r1.Row).Delete
            End If
        Loop
    
    
    End Function
    The error message is

    {returnCode=200;sessionId=61388600-3ed8-42f6-b502-d59efe08aabd;exception=System.FormatException: Input string was not in a correct format.
    at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal)
    at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info)
    at dotNETWebActions_RunScript.RunScriptFromFile.Execute(ActionRequest req, ISession s, IActionRegistry reg)
    at com.iconclude.agent.ActionProxy.Execute(ActionRequest cmd, ISession s, IActionRegistry reg);}
    Why not in correct format ? everything looks fine.

    Best regards
    L
    Last edited by Leonidars; 04-06-2012 at 05:26 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1