[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Getting "Input string was not in a correct format"

Posted on 2006-05-16
4
Medium Priority
?
195 Views
Last Modified: 2010-05-18
I just set up a GridView control on a new page, got the <columns> set up the way I need, and when I tried to "Edit" and "Update", I got the error message above.

I couldn't tell which field was causing the error, so I cut them all out of the control, except for a few text fields that already had values, and started adding them back one at a time to see which was the problem field.

The fields I added back were of assorted data types (text, date, currency, yes/no), and the page was working fine after each restored field.

But finally, when I added back a field that was just a straight number, I got the error.

And when I took that column back out, I STILL got the error!

Any ideas what the problem is?

Thanks

Mark
0
Comment
Question by:mlagrange
  • 2
4 Comments
 
LVL 20

Expert Comment

by:REA_ANDREW
ID: 16690845
please can you post your GridView script please. Oh and how do you bind the data, using the code behind or using the SQL Data Source?

If you used data Reader, then you might have used GetString() for all. Is this the case?
0
 
LVL 19

Accepted Solution

by:
DreamMaster earned 2000 total points
ID: 16690850
Can you find out what the value is that is passed back? You might be passing back a decimal in a format that is not recognized by the datagrid.

I'd check there first.

Regards,
Max.
0
 

Author Comment

by:mlagrange
ID: 16722111
Thanks, DreamMaster - when I looked back at the field type in the database, it was different than what I thought it was.



0
 
LVL 19

Expert Comment

by:DreamMaster
ID: 16731844
You are very welcome indeed.

Glad to have been helpfull,

Regards,
Max.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses the ASP.NET AJAX ModalPopupExtender control. In this article we will show how to use the ModalPopupExtender control, how to display/show/call the ASP.NET AJAX ModalPopupExtender control from javascript, how to show/display/cal…
In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses

872 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question