Double ParseDouble - the input line was not in the correct format - how to fix it?

I keep getting the same error about 3-4 times a day and no luck how to solve this problem. According to the stack trace, the error occurs in the Microsoft.VisualBasic library, and how exactly can I fix this problem?

Here is a report that I send to myself and what the server generates. Any suggestions would be greatly appreciated.

REQUEST
=======
HttpContext.Current.Request.RawUrl: /
UserHostAddress: 207.70.41.78
UserHostName: 207.70.41.78
Request.Browser.Type: IE8
Request.Browser.Platform: Win2000


DATA
====
System.Collections.ListDictionaryInternal


Message
=======
Input string was not in a correct format.

SOURCE
=====
Microsoft.VisualBasic

TARGET SITE
============
Double ParseDouble (System.String, System.Globalization.NumberFormatInfo)

STACK TRACE
=============
   at Microsoft.VisualBasic.CompilerServices.Conversions.ParseDouble (String Value, NumberFormatInfo NumberFormat)
   at Microsoft.VisualBasic.CompilerServices.Conversions.ToInteger (String Value)

Update:

I understand what an error is and what can cause an error. The problem I ran into is figuring out exactly where this error comes from the code. The stack trace tells me that it comes from Visual Basic, but there is nothing else. There are no line numbers, no other information about which function caused this error, there is a zilch to continue, so I remain scratching my head trying to diagnose something, which is likely to end in .dll.

We start Ektron 7.6.6 sp2 if it sheds light on an object.

? , , , - , . .

.

+3
6

, , Double.ParseDouble("bacon"). , . / , , ParseDouble. , (, ), , . ? ? ParseDouble Double.TryParse. , , , ( , ", , " ).

+8

, , - double, . , , , .

- maintennace, $ . , , , .

+1

, ( ?), Double.Parse Double.TryParse.

, , .

0

, double. Double.TryParse Parse.

0

, - . . , :

link.HRef = Globals.BaseURL + Globals.URLRecipe + "?Key=" + Context.Server.UrlEncode(strTemp)

link.HRef = Globals.BaseURL & Globals.URLRecipe & "?RecipeId=" & RecipeId

Double Parse, , strTemp, - . URL- , Parse, RecipeId, int. , URL-.

:

System.FormatException: Input string was not in a correct format.
   at Microsoft.VisualBasic.CompilerServices.Conversions.ParseDouble(String Value, NumberFormatInfo NumberFormat)
   at Microsoft.VisualBasic.CompilerServices.Conversions.ToDouble(String Value, NumberFormatInfo NumberFormat)

VB "+" "&". .

"+", , Int RecipeId URL-, Double .

, :

link.HRef = Globals.BaseURL & Globals.URLRecipe & "?RecipeId=" & RecipeId
0

, ( ). - VB (, , , ). , , ~ 2 , , , stacktrace . ( ).

 Public Function ExceptionToString(ByVal Message As String, ByVal ex As Exception) As String
        Dim Splitter As String = "-------------------------------------------------------------------"
        Dim ex0 As String = Message & vbCrLf & Splitter & vbCrLf
        Dim ex1 As String = ""
        Dim ex2 As String = ""
        Dim ex3 As String = ""
        Dim ex4 As String = ""
        Dim ex5 As String = ""
        Try
            ex1 = ex.Message & vbCrLf & Splitter & vbCrLf
        Catch exc1 As Exception
        End Try
        Try
            ex2 = ex.StackTrace & vbCrLf & Splitter & vbCrLf
        Catch exc1 As Exception
        End Try
        Try
            ex3 = ex.InnerException.Message & vbCrLf & Splitter & vbCrLf
        Catch exc1 As Exception
        End Try
        Try
            ex4 = ex.InnerException.StackTrace & vbCrLf & Splitter & vbCrLf
        Catch exc1 As Exception
        End Try
        Try
            Dim DataStr As String = ""
            For i As Integer = 0 To ex.Data.Keys.Count
                Try
                    DataStr &= ex.Data.Item(ex.Data.Keys(i)) & vbCrLf
                Catch exc2 As Exception
                End Try
            Next
            ex5 = DataStr & vbCrLf & Splitter & vbCrLf
        Catch exc1 As Exception
        End Try

        Dim Result As String = ex0 & ex1 & ex2 & ex3 & ex4 & ex5

        Return Result

    End Function
0

All Articles