Recent update: 2008-3-21
148 byte By
guest at 2008-3-11
When i uninstall the .net frame work1.1 in my system all the XML file i have in my system is getting corrupted.Wat may be the reason for it.Plz help
My XML fails validation.My root element: <UNHCR_RRF xmlns=" http://tempuri.org/ElectronicRRF.xsd" xmlns:dt="urn:schemas-microsoft-com:datatypes" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance" ...
Hi guys. What it the best way to do this? I Have an xml file in this format <Countries> <Country> <ID>1</ID> <Name>Italy</Name> </Country> <Country> <ID>2</ID> <Name>France</Name> </Country> <Country> ...
I appologise if this is an obvious question but I haven't been able to find an answer to it and was wondering if was an issue with visual studio 2005 If I create a new project and attempt to include the xml namespace by Imports System.Xml I get an error stating that the namespace can't be ...
375 byte By
donnyG at 2008-3-3
Hello,I'm just getting familiar with Xml. I have used XmlSerializer to serialize my Data class to XML file. Now I'm trying to append & in some cases delete some data to and from this exisiting XML file . I can append a single string using XmlDocument & XpathNavigator, but don't know ...
I have the following xml source file:<?xml version="1.0" encoding="utf-8" ?> <course id="2555" title="Developing Microsoft .NET Applications for Windows (Visual C# .NET)" length="5 days" source=" http://www.microsoft.com/learning/syllabi/en- us/2555Afinal.mspx"> <module id="1" ...
I'm trying to load the Application.MyApp file and am using Visual Studio 2005 june ctp. This file is a new file generated by visual studio and is the "code behind" all VB Projects in VS 2005. I need to load this file and retreive a piece of information i cant seem to find anywhere else, but ...
Im using XMLSerializer to convert my object to xml string.This works great until i have a object that has a custom collection as a property.This is my collection: public class CarCollection : System.Collections.CollectionBase { public Car this[int index] //This is my indexer { get { return ...
Hi, I have two XSL files. transform.xsl and include.xsl.transform.xsl<?xml version="1.0"?><xsl:stylesheet xmlns:xsl=" http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:import href="include.xsl"/> <xsl:variable name="MyVar"> <xsl:call-template ...
I've found out (from an XslLoadException) that Xpath predicates can't be used in template match statements with XslCompliedTransform. I can use predicates in xsl:for-each statements without getting an exception but it still doesn't work correctly. Non .net implementations seem to have no ...
838 byte By
auhe at 2008-2-24
I have a table ("ssn") in a dataset. I want to write the table to a xml file. When I call Dataset ds = new Dataset("Demographics_Stats");dataAdapter.Fill (ds, "ssn");ds.Tables["ssn"].WriteXml(outputFilename);the output file looks like this:<?xml version="1.0" ...
Hi, I am wondering if it's possible to get attribute of an xml file with a DataSet (not a XmlDataReader) ? I can get the name of attributes from a row but not the value. Any idea ? Or just tell me if I have not to use attributes. Thanks Ad
Ok, I have a program whose solution is composed of (3) projects. I am using ClickOnce as my deployment method and have set the Security Zone to Full Trust.My configuration.dll, which is one of the (3) projects compiled in my solution, tries to write a config.xml file to the ClickOnce data ...
hi all,I need to generate random XML messages out of a schema, what could be the easiest soultion? dot net solution of generating .cs file first and inserting data in stream seems too complicated, also its not generic. I want a generic soultion that would let me create XML data against any XSD ...
634 byte By
NickUk at 2008-2-21
I want to build a web page on the fly based upon data stored in SQL. I currently read the data into a datatable and extract the xml representation. Using xsl I then apply an xslt stylesheet to produce an html representation of my data. This works great, however ...Some of the data contain ...
The current recommended way to validate an XML file is by using schemas stored in the XmlSchemaSet. "The namespace in the XML file, urn:bookstore-schema, identifies which schema in the XmlSchemaSet to use for validation." But if you have to deal with a XML file without a namespace you have to ...
Hi, can anyone let me know how to generate instance from xml schema using c#.Instance can be generated from schema by using XmlSchemaGenerator(),but this requires framework v2.0.As i am working on vs2003 i cant use it. Please HELP! Regards Vinutha
I have a problem using xmlschema when it adds an undesired namespace to my annotations.My Schema is as follows:<?xml version="1.0" encoding="utf-16"?><xsd:schema xmlns:ms="urn:schemas-microsoft-com:xml-data" xmlns:sql="urn:schemas-microsoft-com:mapping-schema" ...
Using VS2005 Beta 2 with office tools and Office 2003 Professional, I am trying to populate a large Word report template (lots of existing static text) with XML. It then allows manual changes on the word document to save changes to the XML. I can do this from the microsoft walkthroughs "Writing ...
[XmlRoot(ElementName="Charges")] public class Charges : List { private Charge _total; public Charges() { } [XmlElement(ElementName="Total")] public Charge Total { get { return ((_total == null) ? new Charge() : _total); } set { _total = ((value == null) ? ...
8738 byte By
Pink at 2008-2-17
XmlSchema in the .NET 1.1 framework is so difficult to use. I want to traverse an XSD. I have code to do it, taken and modified from some sample code I found online. Once I load and complile the schema, I traverse without issue. When I come across a complexType that has a complexContent node, ...
Hi mates, I have a problem when i try deserialize a dataset what has a element (type string) with char ascii like this: blade ? ? ?. It throws a exception, because it find invalid char. But i don′t know why the char 0x1B is invalid. Thx and Regards,
HiWhat is the relevance of XPath queries especially since .NET Framework provides built in support for XML and we can do whatever we want to with XML without ever needing XPath or anything. While this suffices for practical development, i am not sure whether i m true or not. But i would really ...
In this article: http://msdn.microsoft.com/xml/default.aspx?pull=/library/en-us/dnxml/html/SysXMLVS05.asp under #7, the GetAsObject method is being used. Was it removed or changed in beta 2? I'd like to use that method instead of using XmlSerializer since I don't have to specify a type to get ...
How to write a perfect Xml Schema that make my xml file retrieved as tables in dataset?==============================================================Hi,I found using xml instead of databases very amazing to me, which has no license to buy. But i found some problems in writing an xml schema that ...
2887 byte By
visa79 at 2008-2-15
This is really bugging me.. I have an xml file were I want to retrieve info by doing a xpath query with SelectSingleNode and SelectNodes..Net requires you to use namespacemanager, but I cant get it work. The query just gives me null. When I take my namespace xmlns=".." from the root element ...
Hi,I am making a Flash application to display Halo 2 stats using the XML feed supplied by Bungie.net. When the Flash app is online it will not get any data from the XML feed, I have been told that this is because of security features in Flash Player 6+, that require the server which hosts the ...
xsd files create typed datasets in C# Express 2005. All I need do is add it to the project. But in VS 2003 adding it to the project does nothing. I've tried several other xsd files and none of them seems to create typed datasets in VS 2003 the same way they do in C# Express. Any suggestions ...
xsd files create typed datasets in C# Express 2005. All I need do is add it to the project. But in VS 2003 adding it to the project does nothing. I've tried several other xsd files and none of them seems to create typed datasets in VS 2003 the same way they do in C# Express. Any suggestions ...
375 byte By
Rinoa at 2008-2-13
I'm trying to view an image(binary data) into Report Viewer. Is it possible? It wont load. I've tried readxml to a dataset and pass it on into CR.I can view all data except the images eventhough its already a blob field.Please help. I was only able to load this xml image into a picture box ...
I am trying to use XmlWriter to create XML. I need to have the XML Declaration to be <?xml version="1.0" encoding="ISO-8859-1"?>. I tried to set the Encoding in the XmlWriterSettings to "ISO-8859-1". I see the Encoding changes to “ISO-8859-1” in the setting but no matter what I do the ...
Hi, XmlSerializer can serialize data to a file, but SoapFormatter can do the same except that the serialized data in the file is not proper Xml : for instance there is no XmlRoot-element. Why then use SoapFormatter at all ? thanks Chris
I was doing some basic XML processing with XmlReader class (in VisualStudio 2005 Beta 2). The code was supposed to fire events when it encounters either start or end of an XML element. According to .Net documentation the XmlReader does not explicitly read XmlNodeType.EndElement for empty ...
Hi All,I have a simple Windows form that implement the Web Browser component. This form is used to simple display data from a XML file using a style sheet (from a XSL file). Basically, this has been accomplished by the following simple two lines of code (thanks to Microsoft ) protected internal ...
SelectNodes only works for one level when xmnls is present. My xml file has a xmlns declaration and SelectNodes only works for one level. My code: XmlNamespaceManager namespaceManager = new XmlNamespaceManager(xmlDocument.NameTable); namespaceManager.AddNamespace("pf","urn:astm-org:CCR" ); ...
1369 byte By
guest at 2008-2-9
Dear all,I have an XML file like this:Code:<colleagues> <colleague BRANCHID="NH" DEPT="IT"> <NAME>Aluis</NAME> <EMAIL>aluis.do@gmail.com</EMAIL> <PHONE areaCode="02" ext="1604">123456789</PHONE> <MOBILE>0983934645</MOBILE> <FAX...
Hi, I know that XmlReader can validate XML data against XSD. Is there an option to use an XmlWriter which can validate its data as it writes it?
HI! how to create xmlelement without xmldocument? thanks
321 byte By
rsine at 2008-2-7
I am looking to validate an xml document prior to populating my dataset and binding it to a datagrid on my webform. Being this is my first foray into using webforms, xml, schemas, etc. I am not sure how to go about doing the validation. Any help is thus ...
I have a question regarding the new XML DataType in SQL Server 2005. Let's say I have a XML Schema. I use the XSD to generate a set of C# classes, for Serialization/Deserialization purposes. I also use the same XSD to create a XML data column in a database table in SQL Server 2005. When I ...
I have an C#/ASP.NET application. All my pages are generated by xml and xslt via the System.Web.UI.WebControls.Xml.The problem is i get this Cannot convert the operand to 'Result tree fragment'. The xlst workes under IE, but not in .NetHere is a sample of the xslt stylesheet: ...
I can't use System.Security.Cryptography.XML namespace in VS2005, it isn't exist. I need to use KeyInfoName but i can't use because of System.Security.Cryptography.XML. How can i use KeyInfoName in VS2005 ...
Not sure if this is the right place for posting this since I'm using Visual C++ 6 and not .NET, but here it goes. I'm trying to write a small program that works with certain XML files. One of the things I'm trying to get my program to do is look through the XML file finding all tags with a ...
Here's the scenario. I have a cache.xml file which holds path and file information. I read this xml file into a dataset that has 2 tables (Paths, Files). There is a single relation between the two and they are nested. The XML looks as follows: <?xml version="1.0" ...
i have an xml file that looks like this:<?xml version="1.0" encoding="utf-8"?><slideshow> <photo id="47"> <image>/Portals/0/Photos/testArtist/377/BrowserThumb/DSC00539.JPG</image> <caption>wifey</caption> ...
Hi all, I am working on an application that needs to be able to read and lean on theXMLSchema information contained in the web service description(wsdl).After i got a wsdl from address : http://ws.cdyne.com/delayedstockquote/delayedstockquote.asmx?wsdl, I attempt to get its schema and compile ...
2435 byte By
SiJP at 2008-2-4
I have a situation whereby I need to post some xml data at a target web page. Here is my code: Dim objRequest As HttpWebRequest = WebRequest.Create(" http://mywebserver/page.asp") objRequest.ContentLength = sXML.Length objRequest.ContentType = "application/x-www-form-urlencoded" ...
The VS2005 editor complains about the following fragment of XSD: <xs:complexType> <xs:all minOccurs="1" maxOccurs="unbounded"> <xs:element name="Class" type="g:ClassType" minOccurs="1" maxOccurs="1"/> <xs:element name="enumType" type="g:enumType" minOccurs="0" ...
Hello, I need to read a XML file, I've generated a typed DataSet with xsd.exe, but I don't know how to fill the DataSet:DataSet1 ds = new DataSet1();ds.ReadXml("file.xml"); but the dataset seems to be empty, what am I doing wrong?Also, I can't find a way to append a TableAdapter to the ...
I'm trying to write an XML file out, and it's working just fine. I'd like to change the part that writes the "neg99" variable. Instead of writing that value, I'd like to wait until I'm in the "foreach( Field field in f.Fields )" loop to find the value and then write it. The catch is that I ...