Have we got a STRANGE one going here.
We converted from 1.1 to 2.0 about 2 weeks ago and this has been a problem
since then...but only on SOME machines in our development group. The
application runs fine using 1.1 and on 3 of the 8 machines in our group. It
is a Windows application.
Our appliation has many user controls, and panels/viewing areas that we show
in our app. In our application we several areas where we have to take a
string and parse it into other data types; for
instance--ushort.parse(st rSysID). On the problem machines this generates the
following build error:
A first chance exception of type 'System.FormatE xception' occurred in
mscorlib.dll
TestPointSpec: Error TP 774 not a number 0 System.FormatEx ception: Input
string was not in a correct format.
at System.Number.S tringToNumber(S tring str, NumberStyles options,
NumberBuffer& number, NumberFormatInf o info, Boolean parseDecimal)
at System.Number.P arseUInt32(Stri ng value, NumberStyles options,
NumberFormatInf o numfmt)
at System.UInt16.P arse(String s, NumberStyles style, NumberFormatInf o info)
at System.UInt16.P arse(String s)
at ConfigurationFi les.TestPointSp ecificationFile .ParseEnumerati on(UInt16
specID, String wholeEnum) in D:\C-5 RERP\PVCS
7-26-06\Common\Confi gurationFiles\T estPointSpecifi cationFile.cs:l ine 357
In other parts of the application, we may be using the string in a different
way(ie. we use the string/convert it to an int and use it as an index), and
it gets past the build process, but at run time generates the following
error, when trying to use a "0" in a string:
System.FormatEx ception was unhandled
Message="Input string was not in a correct format."
Source="mscorli b"
StackTrace:
at System.Number.S tringToNumber(S tring str, NumberStyles options,
NumberBuffer& number, NumberFormatInf o info, Boolean parseDecimal)
at System.Number.P arseUInt32(Stri ng value, NumberStyles options,
NumberFormatInf o numfmt)
at System.UInt16.P arse(String s, NumberStyles style, NumberFormatInf o
info)
at System.UInt16.P arse(String s)
at ApplicationFram e.SubsystemBrow serControl.GetS electedRows(Dat aGrid
dg) in D:\C-5 RERP\PVCS
7-26-06\PCIU_CSCI\Us erInterfaceComp onents\Subsyste mBrowserControl .cs:line 1290
at
ApplicationFram e.SubsystemBrow serControl.addT PmenuItem_Click (Object sender,
EventArgs e) in D:\C-5 RERP\PVCS
7-26-06\PCIU_CSCI\Us erInterfaceComp onents\Subsyste mBrowserControl .cs:line 1052
We know it has something to do with having a "0" in a string, but have NO
idea, of why it happens on only some of the machines and not all (luckily I'm
not one of the problem machines), and also why it works with 1.1 version of
the framework, and not 2.0.
Anyone have any ideas of what the problem is, or where we start looking?
My apologies for the length of the post. Thanks in advance for any help.
WhiteWizard
aka Gandalf
MCSD.NET, MCAD, MCT
We converted from 1.1 to 2.0 about 2 weeks ago and this has been a problem
since then...but only on SOME machines in our development group. The
application runs fine using 1.1 and on 3 of the 8 machines in our group. It
is a Windows application.
Our appliation has many user controls, and panels/viewing areas that we show
in our app. In our application we several areas where we have to take a
string and parse it into other data types; for
instance--ushort.parse(st rSysID). On the problem machines this generates the
following build error:
A first chance exception of type 'System.FormatE xception' occurred in
mscorlib.dll
TestPointSpec: Error TP 774 not a number 0 System.FormatEx ception: Input
string was not in a correct format.
at System.Number.S tringToNumber(S tring str, NumberStyles options,
NumberBuffer& number, NumberFormatInf o info, Boolean parseDecimal)
at System.Number.P arseUInt32(Stri ng value, NumberStyles options,
NumberFormatInf o numfmt)
at System.UInt16.P arse(String s, NumberStyles style, NumberFormatInf o info)
at System.UInt16.P arse(String s)
at ConfigurationFi les.TestPointSp ecificationFile .ParseEnumerati on(UInt16
specID, String wholeEnum) in D:\C-5 RERP\PVCS
7-26-06\Common\Confi gurationFiles\T estPointSpecifi cationFile.cs:l ine 357
In other parts of the application, we may be using the string in a different
way(ie. we use the string/convert it to an int and use it as an index), and
it gets past the build process, but at run time generates the following
error, when trying to use a "0" in a string:
System.FormatEx ception was unhandled
Message="Input string was not in a correct format."
Source="mscorli b"
StackTrace:
at System.Number.S tringToNumber(S tring str, NumberStyles options,
NumberBuffer& number, NumberFormatInf o info, Boolean parseDecimal)
at System.Number.P arseUInt32(Stri ng value, NumberStyles options,
NumberFormatInf o numfmt)
at System.UInt16.P arse(String s, NumberStyles style, NumberFormatInf o
info)
at System.UInt16.P arse(String s)
at ApplicationFram e.SubsystemBrow serControl.GetS electedRows(Dat aGrid
dg) in D:\C-5 RERP\PVCS
7-26-06\PCIU_CSCI\Us erInterfaceComp onents\Subsyste mBrowserControl .cs:line 1290
at
ApplicationFram e.SubsystemBrow serControl.addT PmenuItem_Click (Object sender,
EventArgs e) in D:\C-5 RERP\PVCS
7-26-06\PCIU_CSCI\Us erInterfaceComp onents\Subsyste mBrowserControl .cs:line 1052
We know it has something to do with having a "0" in a string, but have NO
idea, of why it happens on only some of the machines and not all (luckily I'm
not one of the problem machines), and also why it works with 1.1 version of
the framework, and not 2.0.
Anyone have any ideas of what the problem is, or where we start looking?
My apologies for the length of the post. Thanks in advance for any help.
WhiteWizard
aka Gandalf
MCSD.NET, MCAD, MCT
Comment