473,611 Members | 2,229 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Input string in incorrect form..Help needed urgently!!

1 New Member
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.FormatEx ception: Input string was not in a correct format.

Source Error:

Line 237: Dim validNow As Integer = 1
Line 238: 'Dim jobAmount As Decimal = JobInformation. GetJobAmt(class iDDL.SelectedVa lue)
Line 239: Dim jobAmount As Decimal = Convert.ToDecim al(JobInformati on.GetJobAmt(CI nt(classiDDL.Se lectedValue)))
Line 240: 'Dim jobAmount As Decimal = Convert.ToInt32 (JobInformation .GetJobAmt(clas siDDL.SelectedV alue))
Line 241: Dim reason, message As String


Source File: \\hera\webroot$ \veyo\chits\CCL Chits\CreateCCL Chit.aspx.vb Line: 239

Stack Trace:

[FormatException : Input string was not in a correct format.]
Microsoft.Visua lBasic.Compiler Services.Double Type.Parse(Stri ng Value, NumberFormatInf o NumberFormat) +195
Microsoft.Visua lBasic.Compiler Services.Intege rType.FromStrin g(String Value) +95

[InvalidCastExce ption: Cast from string "" to type 'Integer' is not valid.]
Microsoft.Visua lBasic.Compiler Services.Intege rType.FromStrin g(String Value) +210
veyo.CreateCCLC hit.NextButton1 _Click(Object sender, EventArgs e) in \\hera\webroot$ \veyo\chits\CCL Chits\CreateCCL Chit.aspx.vb:23 9
System.Web.UI.W ebControls.Butt on.OnClick(Even tArgs e) +108
System.Web.UI.W ebControls.Butt on.System.Web.U I.IPostBackEven tHandler.RaiseP ostBackEvent(St ring eventArgument) +57
System.Web.UI.P age.RaisePostBa ckEvent(IPostBa ckEventHandler sourceControl, String eventArgument) +18
System.Web.UI.P age.RaisePostBa ckEvent(NameVal ueCollection postData) +33
System.Web.UI.P age.ProcessRequ estMain() +1292


here is the code which i am using.......... ....

Expand|Select|Wrap|Line Numbers
  1.  Dim jobAmount As Decimal = Convert.ToDecimal(JobInformation.GetJobAmt(CInt(classiDDL.SelectedValue)))
  2.  
  3.         If Not chitEdit Then
  4.             ' ====  If only the above is satisfied, continue with the CCL. ====
  5.             If Not transfer Then
  6.                 Utilities.CreateMessageAlert(Me, message, "alert")
  7.                 Return
  8.             End If
  9.  
  10.             ' Create CCL chit
  11.             ' -------------------
  12.  
  13.  
  14.         Else 'i.e. chitEdit = true
  15.  
  16.             If Not transfer Then
  17.                 Return
  18.             End If
  19.  
  20.             chitID = CInt(ChitIDLabel.Text)
  21.  
  22.             If Not Chit.EditChit(chitID, caseID, chitDate, chitSigneeRCN, chitSigneeDesigID, _
  23.                     effectiveDate, RemarksAndCC1.ChitRemarks(), CInt(Context.Items("userID"))) Then
  24.                 'Error to user : ERROR in saving edited chit.
  25.                 Response.Redirect("/veyo/Error.aspx?eid=21&chitID=" & chitID)
  26.                 Return
  27.             End If
  28.  
  29.  
  30.             'JobPanel.Enabled = False
  31.  
  32.  
  33.  
  34.             ' Delete all Havaalaadhey CaseIDs and add new
  35.             If Not DeleteHavaalaadheyCaseIDs(chitID) Then
  36.                 Response.Redirect("/veyo/Error.aspx?eid=42&chitID=" & chitID)
  37.                 Return
  38.             End If
  39.  
  40.             If Not SaveHavaalaadheyCaseIDs(caseID, chitID) Then
  41.                 Response.Redirect("/veyo/Error.aspx?eid=41&chitID=" & chitID)
  42.                 Return
  43.             End If
  44.  
  45.             ' Delete and Save Chit CC Offices
  46.             If Not DeleteChitCCOffices(chitID) Then
  47.                 Response.Redirect("/veyo/Error.aspx?eid=45&chitID=" & chitID)
  48.                 Return
  49.             End If
  50.  
  51.             If Not InsertChitCCOffices(chitID, RemarksAndCC1.GetCCOfficeList) Then
  52.                 Response.Redirect("/veyo/Error.aspx?eid=44&chitID=" & chitID)
  53.                 Return
  54.             End If
  55.  
  56.  
  57.             ' Edit Job History
  58.             If Not JobInformation.UpdateJobHistory(RCN, chitID, effectiveDate, chitDate, _
  59.                 BridgeUntilTB.Text, RemarksAndCC1.ChitRemarks, Context.Items("userID")) Then
  60.                 Response.Redirect("/veyo/Error.aspx?eid=50&chitID=" & chitID)
  61.                 Return
  62.             End If
  63.  
  64.             ' Delete any Additional Remarks previously written and
  65.             ' check whether there are any additional remarks for original copy and save that
  66.             ' tbl_chitsAdditionalRemarks
  67.             If Not DeleteChitAdditionalRemarks(chitID) Then
  68.                 Response.Redirect("/veyo/Error.aspx?eid=47&chitID=" & chitID)
  69.                 Return
  70.             End If
  71.  
  72.             If Not RemarksAndCC1.OriginalCopyChitRemarks = "" Then
  73.                 Chit.InsertChitAdditionalRemarks(chitID, RemarksAndCC1.OriginalCopyChitRemarks)
  74.             End If
  75.  
  76.             Dim pathname As String = Chit.GetDisplayURL(chitType) & "?chitID=" & chitID
  77.             Response.Redirect(pathname)
  78.  
  79.  
  80.         End If
  81.  
  82.     End Sub
  83.  
  84.     Private Sub ClassDDL_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ClassDDL.SelectedIndexChanged
  85.         toSalaryDDL.DataSource = JobInformation.GetClassSalaries(ClassDDL.SelectedValue)
  86.         toSalaryDDL.DataTextField = "salary"
  87.         toSalaryDDL.DataValueField = "classSalID"
  88.         toSalaryDDL.DataBind()
  89.         toSalaryDDL.Enabled = True
  90.  
  91.         classiDDL.DataSource = JobInformation.GetClassSalaries(ClassDDL.SelectedValue)
  92.         classiDDL.DataTextField = CInt("classID")
  93.         classiDDL.DataValueField = "classSalID"
  94.         'classiDDL.SelectedValue = Nothing
  95.         classiDDL.DataBind()
  96.         classiDDL.Enabled = True
  97.  
  98.     End Sub 
Sep 14 '06 #1
0 2539

Sign in to post your reply or Sign up for a free account.

Similar topics

2
12589
by: Tom | last post by:
I'm trying to find a good, solid function that sanitizes string values for form validation. The user notes on php.net offer the following: http://www.php.net/manual/en/function.strip-tags.php#36574 And a slight revision of this: http://www.php.net/manual/en/function.strip-tags.php#37562 These seem to do different things with tag attributes. So I've
0
1461
by: Kamliesh Nadar | last post by:
Hi I am developing a software using VB.NET I am facing following problems - 1. Though I have placed the NotifyIcon control on the window service application, after starting the service I am not able to view the icon on the system tray. 2. Secondly how to add a new item in the Window explorer
15
3344
by: Alfonso Morra | last post by:
Hi, I have some code from an example, that I want to retrofit into my project. The code from the example has the following line: SharedAppenderPtr myAppender( new RollingFileAppender("MyAppender")) I want to move this line of code to a constructor in a wrapper class, so that I can determine the appropriate Appender name during the object's
0
988
by: Amit | last post by:
hi friends , I am stuck with a problem and need ur help. I have knowledge management application where i am using third party forums that needs login.I have username and password for forums which is same as the one used in my application now i want user to login into forums as soon as user logg's in the application. I have some clues i can do it using xmlhttp , but how any help will be heartly appriciated.
2
1188
by: walterd | last post by:
Hi Can anyone help me with the following problem. In my web application, I have a class that use the MessageBox class to display messages. My only problem is, messages pop-up on the server screen, not on the client where the user is logged in. Can someone out there help me with this problem? The JavaScript Alert is not appropriate as it only show all messages using the Exclamation. If anyone have a nice script that have all the...
3
1094
by: gauravkg via DotNetMonster.com | last post by:
Hi i have a problem I have a product product_name=taj Mahal product_id=111 i and different users will be putting reviews title and review description. this is the following xml file i have make <reviews>
0
2951
by: prad | last post by:
Hi, Following java code returns 24 result sets.It counts number of rows in the first result set correctly.But doesnt count rows from next result set. When I debugged the code I found out that first time it enters in the loop while(rs.next()).But from the next result set it doesn't enter that loop as rs.next() returns false.DB2 is used as backend. thanx 4 help. import java.sql.*; import java.io.*; public class exportdds33 { static...
1
1603
by: Pumpkin Carver | last post by:
I have a form that has a listview on it and a serious of strings in the listiew. When i doubel click on the listview item it opens a new form and displays the text that i pass to the constructor. What i am trying to do now is have a previous/next button on the form i just opened and have it go through the list of items depending on whats previous or next to that item. I pretty much have the logic for that, the only issue i cant seem to...
10
1567
by: Silvana | last post by:
Hi, I'm new to Access or as a matter of fact it's the first time that I'm working with a database. I'm working on a program in Access for a class project and I'm having some trouble with the login application. The program is basically a database for a small store which allows the employees to login with or without administrator access. The usename and password for each employee is stored in tblEmployee under strUseName and strPassword. The...
0
8596
Oralloy
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...
0
8561
jinu1996
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...
1
8240
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,...
0
8411
tracyyun
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...
1
6072
isladogs
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...
0
4042
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2546
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1692
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1411
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.