473,811 Members | 3,026 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

save dataSet in xml file

im trying to save the content of a DataSet to xml file but im getting the
message-
" This file has modified outside of the source editor
do you want to reload it ? "
what im missing?

this is what i have wrote-
dataset1.Accept Changes
dataset1.WriteX ml("PathFile.xm ")

thanks

Jul 21 '05 #1
4 1536
Hi,

Likely that you have opened the XML file in your VS .NET editor and you are
trying to overwrite that file through your program.

Click Yes on the prompt to see the new XML file content in the editor.

"s-galit" <sg****@discuss ions.microsoft. com> wrote in message
news:55******** *************** ***********@mic rosoft.com...
im trying to save the content of a DataSet to xml file but im getting the
message-
" This file has modified outside of the source editor
do you want to reload it ? "
what im missing?

this is what i have wrote-
dataset1.Accept Changes
dataset1.WriteX ml("PathFile.xm ")

thanks
Jul 21 '05 #2
i dont want the user to see that message
what can i do?

"Shiva" wrote:
Hi,

Likely that you have opened the XML file in your VS .NET editor and you are
trying to overwrite that file through your program.

Click Yes on the prompt to see the new XML file content in the editor.

"s-galit" <sg****@discuss ions.microsoft. com> wrote in message
news:55******** *************** ***********@mic rosoft.com...
im trying to save the content of a DataSet to xml file but im getting the
message-
" This file has modified outside of the source editor
do you want to reload it ? "
what im missing?

this is what i have wrote-
dataset1.Accept Changes
dataset1.WriteX ml("PathFile.xm ")

thanks

Jul 21 '05 #3
Option 1: From VS .NET IDE, select menu Tools, Options. In
Environment/Documents section, check 'Detect when file is changed outside
the environment' and 'Auto-load changes (if not....)' options and click OK.

Option 2: Use a different file name each time you save the dataset to an XML
file.

HTH.

"s-galit" <sg****@discuss ions.microsoft. com> wrote in message
news:11******** *************** ***********@mic rosoft.com...
i dont want the user to see that message
what can i do?

"Shiva" wrote:
Hi,

Likely that you have opened the XML file in your VS .NET editor and you are trying to overwrite that file through your program.

Click Yes on the prompt to see the new XML file content in the editor.

"s-galit" <sg****@discuss ions.microsoft. com> wrote in message
news:55******** *************** ***********@mic rosoft.com...
im trying to save the content of a DataSet to xml file but im getting the
message-
" This file has modified outside of the source editor
do you want to reload it ? "
what im missing?

this is what i have wrote-
dataset1.Accept Changes
dataset1.WriteX ml("PathFile.xm ")

thanks

Jul 21 '05 #4
Thank you !!!!!!!!!!!!
it helped
Jul 21 '05 #5

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

Similar topics

4
6235
by: Jaime | last post by:
I have to save a dataset to xml and for efficiency I like to get rid of the namespace prefix d2p1: can any one help thanks jaime
2
2316
by: deko | last post by:
I create an XmlDataDocument Dataset when the main form of my WinForms app opens. The user will make changes to the Dataset, and then those changes should be saved to the XML file when the code runs xdd.Save(xmlFile). But I get an error when I try to save the Dataset back to the XML file: "The process cannot access the file "C:\Projects.xml" because it is being used by another process." Is this because I'm in Debug mode? How do I persist...
4
4539
by: Jae | last post by:
I'm writing a web application that exports and imports excel files. The application gets a list of users and their info and displays it in a datagrid .The user then selects to save the file as a tab delimited file or an excel file. The application then saves the file in the correct format. The flip side is for the user to import/upload the file to the server The application must be able to import the excel file and read the contents. I...
2
1899
by: buran | last post by:
Dear ASP.NET Programmers, I am saving the tables of a dataset into an XML file. I want to save the XML file into the database, then retireve it as a dataset. I use the following code: ds.WriteXml("C:\Inetpub\wwwroot\database2\richtext\burak.xml") where ds is my dataset.
2
3124
by: DraguVaso | last post by:
Hi, I found some examples for storing the FormSettings of a Form in an XML-file, but none of these could match my criteria: What I am looking for is the possibility to save the FormSettings of multiple Instances of 1 form. I have a Form frmSource from which I have multiple Instances, each with a unique Identifier. So when I Load or Close a specific instance, I want to load or save the Settings (Top, Height, Width, etc) in an XML-file....
4
381
by: s-galit | last post by:
im trying to save the content of a DataSet to xml file but im getting the message- " This file has modified outside of the source editor do you want to reload it ? " what im missing? this is what i have wrote- dataset1.AcceptChanges dataset1.WriteXml("PathFile.xm")
10
39529
by: Henok Girma | last post by:
Hello Gurus, I want to save the state of an unbound DataGridView on my Windows Form application to an XML file so i can later load it back.. Basically, on my form I have a DataGridView, it's got some DataGridViewTextBoxCell, DataGridViewComboBoxCell etc, i want to export all that to XML.. Any help is greatly appreciated.
6
1886
by: alexia.bee | last post by:
Hi all, I am new to C# so please bear me :). I have an app which uses datagridview. it has 8 columns. I also have struct which has 8 members(the same as the datagridview). when I add row to the gridview, i add the same data to this staruct and then add this struct instance to a list. the app creates more then one file with different name. depending on
5
7621
by: countnazgul | last post by:
Hello, I've got very odd problem. I use windows application to store files in data base (MySql) and then to extract this files from data base and save it on hdd. But when i save them back to hdd tihs files are 1Kb less from original file. When i insert pictures this 1kb obviously is not imported and the pictures is shown. But other files when try to be opened is corrupted or if they open some error message is shown. So the code that i use to...
0
9605
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,...
0
10647
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
10386
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
10398
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
10133
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
7669
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
6889
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5554
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
4339
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

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.