Hello folks
I have recently been studying a book called "sams teach yourself asp.net 2.0 in24 hours by scott mitchell. I have reached page 614 but when i tried to run an asp page called Photoadmin/default.aspx i got the following message and info.
Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.FormatEx ception: Input string was not in a correct format.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[FormatException : Input string was not in a correct format.]
System.Number.S tringToNumber(S tring str, NumberStyles options, NumberBuffer& number, NumberFormatInf o info, Boolean parseDecimal) +2752899
System.Number.P arseInt32(Strin g s, NumberStyles style, NumberFormatInf o info) +102
System.String.S ystem.IConverti ble.ToInt32(IFo rmatProvider provider) +43
System.Convert. ChangeType(Obje ct value, TypeCode typeCode, IFormatProvider provider) +293
System.Web.UI.W ebControls.Para meter.GetValue( Object value, String defaultValue, TypeCode type, Boolean convertEmptyStr ingToNull, Boolean ignoreNullableT ypeChanges) +248
System.Web.UI.W ebControls.SqlD ataSourceView.A ddParameters(Db Command command, ParameterCollec tion reference, IDictionary parameters, IDictionary exclusionList, String oldValuesParame terFormatString ) +547
System.Web.UI.W ebControls.SqlD ataSourceView.E xecuteInsert(ID ictionary values) +304
System.Web.UI.D ataSourceView.I nsert(IDictiona ry values, DataSourceViewO perationCallbac k callback) +68
System.Web.UI.W ebControls.Deta ilsView.HandleI nsert(String commandArg, Boolean causesValidatio n) +394
System.Web.UI.W ebControls.Deta ilsView.HandleE vent(EventArgs e, Boolean causesValidatio n, String validationGroup ) +609
System.Web.UI.W ebControls.Deta ilsView.OnBubbl eEvent(Object source, EventArgs e) +88
System.Web.UI.C ontrol.RaiseBub bleEvent(Object source, EventArgs args) +35
System.Web.UI.W ebControls.Deta ilsViewRow.OnBu bbleEvent(Objec t source, EventArgs e) +109
System.Web.UI.C ontrol.RaiseBub bleEvent(Object source, EventArgs args) +35
System.Web.UI.W ebControls.Link Button.OnComman d(CommandEventA rgs e) +85
System.Web.UI.W ebControls.Link Button.RaisePos tBackEvent(Stri ng eventArgument) +153
System.Web.UI.W ebControls.Link Button.System.W eb.UI.IPostBack EventHandler.Ra isePostBackEven t(String eventArgument) +7
System.Web.UI.P age.RaisePostBa ckEvent(IPostBa ckEventHandler sourceControl, String eventArgument) +11
System.Web.UI.P age.RaisePostBa ckEvent(NameVal ueCollection postData) +170
System.Web.UI.P age.ProcessRequ estMain(Boolean includeStagesBe foreAsyncPoint, Boolean includeStagesAf terAsyncPoint) +4921
I have also included the event handlers for the above problem:
Version Information: Microsoft .NET Framework Version:2.0.507 27.42; ASP.NET Version:2.0.507 27.42
Partial Class PhotoAdmin_Defa ult
Inherits System.Web.UI.P age
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArg s) Handles Me.Load
UserIdValue.Tex t = Membership.GetU ser().ProviderU serKey.ToString ()
End Sub
Protected Sub dvPictureInsert _ItemInserting( ByVal sender As Object, ByVal e As System.Web.UI.W ebControls.Deta ilsViewInsertEv entArgs) Handles dvPictureInsert .ItemInserting
e.Values("UserI d") = Membership.GetU ser().ProviderU serKey
e.Values("Uploa dedOn") = DateTime.Now
End Sub
End Class
thanx for your help
john
1 4523 jhardman 3,406
Recognized Expert Specialist
Hello folks
I have recently been studying a book called "sams teach yourself asp.net 2.0 in24 hours by scott mitchell. I have reached page 614 but when i tried to run an asp page called Photoadmin/default.aspx i got the following message and info.
Input string was not in a correct format.
What enctype was specified in your form?
Jared
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Jim |
last post by:
im using asp.net, C# to enter data into a table in sql
server...however im getting this error:
Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it originated in the code.
Exception Details: System.FormatException: Input string was not in a
correct format.
|
by: lianfe_ravago |
last post by:
Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.FormatException: Input string was not in a correct format.
Source Error:
Line 457: <tr>
|
by: blackg |
last post by:
Input string not in correct format
--------------------------------------------------------------------------------
I am trying to view a picture from a table. I am getting this error
Input string not in the correct format.
Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of
the current web request. Please review the stack trace for more
information about the error and where it...
|
by: amitbadgi |
last post by:
Welcome back amitbadgi | Logout | Faq
Knowledge Discovery Keys
COMPUTER PROGRAMMING, DATA MINING, STATISTICS, ARTIFICIAL INTELLIGENCE
* Settings
* Photos
* Lists
* MVPs
* Forums
* Blogs
|
by: amitbadgi |
last post by:
I am gettign this error, while migration an app to asp.net
Exception Details: System.FormatException: Input string was not in a
correct format.
Source Error:
Line 19: Dim enddate = request.QueryString("enddate")
Line 20:
Line 21: if cint(eventid) = "0" then
| |
by: hudhuhandhu |
last post by:
have got an error which says Input string was not in a correct format. as follows..
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.FormatException: Input string was not in a correct format.
Source Error:
Line 237: Dim validNow As Integer = 1
Line...
|
by: Anonieko |
last post by:
Are there any javascript codes there?
Answer: Yes
On the PageLoad event call InitialClientControsl as follows
/// <summary>
/// This will add client-side event handlers for most of the
form controls so
|
by: sehguh |
last post by:
Hiya Folks,
I am Currently using windows xp. Also using Visual Web Developer 2005 and Microsoft Sql server 2005.
The main page consists of an aspx page and a master page.
The page also consists of a label control(hidden when run in browser).
Also an Sql data source control connected to database tables for a photo album.
Also label web control ID=UserIdValue.
Also a Details View control ID=dvPictureInsert
Problem is how to work out...
|
by: differentsri |
last post by:
THIS IS AN ASP.NET 1.1 APPLICATION IAM TRYING TO UPDATE THE FIELD BUT I AM NOT ABLE TO UPDATE IT?
CAN U TELL THE REASON ?
IT IS GIVING THE FOLLOWING ERROR
BELOW I HAVE ALSO GIVEN THE CODE OF THE PROGRAM
PLEASE HELP ME
Server Error in '/WebApplication1' Application.
--------------------------------------------------------------------------------
Input string was not in a correct format.
Description: An unhandled exception occurred...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |