473,404 Members | 2,174 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

Updation Problem!!

While updating records using Command Object, its poping error The Connection
is closed, but at the same time if i add the record no such error arises.
the source code is as under, plz help :

private void cmdEdit_Click(object sender, System.EventArgs e)

{try{

String strIsDerived = (rbIsDerived.Checked?"1":"0");

String strSQL = "Update UOM set UOMName = '" + txtUOMName.Text + "',UOMUNITS
= " + txtUnits.Text + ",UOMCODE = '" + txtUOMCode.Text + "', ISDERIVED = '"
+ strIsDerived + "', PARENTUOMID = '" + txtParent.Text + "' Where UOMID = '"
+ txtUOMID.Text + "'";

OracleCommand cmd = new OracleCommand(strSQL,cnn);

cmd.ExecuteNonQuery();

}

catch(OracleException oe)

{

MessageBox.Show("Oracle Exception " + oe.Message + ": Unable to Update");

}

catch(Exception ex)

{

MessageBox.Show("Exception " + ex.Message + ": Unable to Update");

}

}

While deleting the record its hanged waiting internally for sum other
function to finish off, its hanged when i call cmdDelete.ExecuteNonQuery(),
the code is similar to wats been mentioned above, except the query is
"Delete from ..."
Nov 15 '05 #1
0 945

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Lakshmi Narayanan.R | last post by:
Hi Experts I am new to .NET. I need great explanation for "the updation in the disconnected data". How it is handled. That is, if mutiple user is interacting with the data, one will delete another...
1
by: Babz | last post by:
Hi, How I can prevent concurrent updation of a records in .net. I am using Dataset which is disconnected from the data source. In this situation if two users opens the same record, modifies the...
0
by: prashant | last post by:
Hi, I am trying to set up Transactional replication with immediate updation. The configuration is as follows: 1. Publisher is SQL server 2000 Enterprise Edition, and Distributor is on the...
0
by: smasadhaque | last post by:
We are using a third party control C1FlexGrid to display the real time data. The data is received from a server on a different thread, processed and then stored in a dataset table. This table is...
0
by: ppuniversal | last post by:
hello, I am making an application where I have to copy the values of some of the tuples(which are not already copied into the files) from my database in MySQL into two files.Now I have an attribute...
2
by: getnanda | last post by:
I am using 400 text box in my Form. Updating Text property of all the 400 Text boxes in the Form takes more than 30 milliseconds. Is there any way to reduce this time in c# .net. //Sample code...
1
by: gauravtechie | last post by:
Hi all, I have a javascript that is reloading itself on every menu change, Now the problem is that the values of the product doesn`t reset itself on catalogue change, the code is <html>...
1
by: roshan56us | last post by:
Hi, i have problem in updation of access database, which is in backend and Visual basic as front end. its using 800 records in MS-Access but,while updating the database, it doesn't update sometime...
1
by: siri11 | last post by:
Hi everyone!!!!!!!!! If i update a record in a table in sqlserver from front end (c#.net),using a stored procedure for updating then after updation if i open the table then it is showing the same...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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...
0
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...
0
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...

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.