473,402 Members | 2,046 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,402 software developers and data experts.

datarow not updating...

using the following code, I've been unable to write an updated xml
document.I can see the xml
file get refreshed but even at that, it writes in the original contents.
these procs come from a
databaseengine class i created, theDataStore is a dataset that gets loaded
from a xml data file
when the constructor runs.

the database engine sits in a application variable within a IIS application
and only one copy ever
exist in memory. updateUser is called via delegate.

the dataset in memory, and thus the xml file that gets written dont seem to
get updated.

public void updateUser (zDatabaseObject theObject)
{
zUser theUser = (zUser) theObject;

DataRow theRow;
theRow = theDataStore.Tables["tblUsers"].Rows.Find(theUser.UserID);

theRow["FullName"] = theUser.FullName;
theRow["UserName"] = theUser.UserName;
theRow["Password"] = theUser.Password;
theRow["Email"] = theUser.Email;
theRow.AcceptChanges();

saveDataStore();
}

private void saveDataStore()
{
theDataStore.AcceptChanges();
theDataStore.WriteXml(theRootDirectory + "zDatabase.xml");
}
Nov 18 '05 #1
0 915

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

Similar topics

3
by: spammy | last post by:
hi all, my code currently reads as the following: ////// double tmpposition = (double)dr + pos; dr = tmpposition;
3
by: Jon S via DotNetMonster.com | last post by:
Hi all, I'm having a problem updating a simple change I've made to a Access 2000 table through databinding. The error I get is : An unhandled exception of type...
0
by: Doug | last post by:
I've got a strongly-typed dataset with 2 related tables in it ("Staff" and "Roles"). I want to make a change to the parent Staff row and also to its child Role row. I'm having difficulty figuring...
6
by: BB | last post by:
Hello all, I am using the currency manager in VB to navigate a dataset. I know how to use .position to loop through the rows, but what I want to do is *get* the position of the row I just...
2
by: Steve Amey | last post by:
Hi all I am binding a DataRow to some controls on a form. When I've finished editing the DataRow I click on a toolbar button to save the changes. If the focus is on a particular control, the...
0
by: Job Lot | last post by:
I have designed a user interface with controls bound to data using Data Source Window. Draging and dropped customer table from Data Source Window created various navigation controls and a...
2
by: rn5a | last post by:
When a DataGrid is in the editable mode, users can change the quantity of the items that are currently in his shopping cart by entering a new quantity in a TextBox. After changing the quantity, a...
6
by: Manikandan | last post by:
Hi, I need to insert the datetime with milliseconds value into a datarow. My code as below DataTable testDataTable=new DataTable(); testDataTable.Columns.Add("updatedDateTime",...
0
by: Infog | last post by:
What is the difference between these two? If I use one or the other when adding or updating a strongly typed DataTable's DataRow, will there be any difference in the result? I can't find an...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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,...
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...
0
agi2029
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,...
0
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...

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.