perfectxml.com
 Basic Search  Advanced Search   
Topics Resources Free Library Software XML News About Us
home » focus » msxml » ask a question » past questions & answers Thursday, 11 October 2007
 
NEWS
MSXML 4.0 SP2 now available!

 
MSXML
Basics
DOM
SAX
XPath
XSLT
Schemas
SOM
HTTP Access
.NET
Data Islands
Ask a Question
   Past Q&As
C++ Samples
DLL/Version Info
Reference Guide
Books
KB Articles
   HOW TO
   SAMPLE
   INFO
   BUG/PRB
   FIX
   Misc.
MSXML Tips
   August 2002
   September 2002
MSXML Tools

Microsoft XML Core Services


Click here to ask a MSXML Question to perfectxml.com Team

Past Questions and Answers

Page: 1  2  3  4  5  

Question 93: I am using MSXML4 ServerXMLHTTP to POST some name=value formatted data to an ASP page, however the ASP page does not seem to receive the POSTed data. If I send a HTTP GET request and pass name=value formatted data as the URL parameters, the ASP QueryString properly receives the value, however if I send a POST request to the same ASP page by passing the name=value formatted data with the send method, the ASP Form collection does not seem to receive the POSTed data values. (2/11/2003) (Viewed 3741 times)
Question 92: Is there a way to find out the namespaces prefixes used in the document? For instance, I have the following XML document:
<?xml version="1.0"?>
<group xmlns:p='urn:example-org:People' xmlns:ci="IjustWannaFindThisPrefix">
  <p:date>1970-09-30</p:date>
  <p:degrees>67.5</p:degrees>
</group>
I just want to find out the namespaces prefixes used (p and ci in the above sample XML). (1/26/2003) (Viewed 1837 times)
Question 91: I have an ASP page that write special characters such as pound and Euro to the response stream. When I call this page using either XMLHTTP or ServerXMLHTTP, the responseText contains question mark (?) instead of special character symbols ( or ). (1/10/2003) (Viewed 11275 times)

Question 90: I have an XML document that contains hex encoded data. The XML document refers to an XSD schema document, that defines the element data type as xs:hexBinary. I am processing this XML document using MSXML4 SP1 in C++. When I retrieve the hex data using nodeTypedValue, the value is returned as BSTR variant instead of byte array variant. How do I get back the value as byte array variant? (1/14/2003) (Viewed 2679 times)
Question 89: Is it possible to use MSXML inside T-SQL script? I am writing a SQL Server 2000 stored procedure and need to process some XML. Basically, I am storing XML data in a table column, and in the stored procedure, I need to read that XML column value, update it and save it back to the table column. Can I use MSXML inside a stored procedure to do this? (12/28/2002) (Viewed 4257 times)
Question 88: I am using MSXML SAX to parse the XML document. Some of the attribute values contain newline characters. However, when I try to retrieve the attribute value using the ISAXAttributes::getValue in my startElement implementation, the parser removes the newline characters from the attribute values! Is there a way to preserve the newline character (or for that matter any of the whitespace characters, such as tab, space, and line break) in the attribute values? (12/22/2002) (Viewed 2012 times)

Question 87: I am using MSXML 4 to validate an XML document during the load, by setting the validateOnParse to true and providing the XSD document reference in the XML document root element. For example:
<?xml version="1.0" encoding="UTF-8"?>
<RootElement 
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
              xsi:noNamespaceSchemaLocation="c:\myfolder\MySchema.xsd">
...
</RootElement>
The XML validation works perfect if the MySchema.xsd is found in the specified folder above, but if the XSD schema file is not found in the specified folder, looks like validation is not performed, and document load returns true. How can I check if the XSD schema was found and validation actually occurred? (12/18/2002) (Viewed 2011 times)
Question 86: Can you show me an example of using MSXML DOM and SAX, both together, in a single C++ application? (12/15/2002) (Viewed 3170 times)
Question 85: I am using MSXML 4.0 in a C++ application, and I have a function to which I pass XML string. This function loads the XML text (using loadXML method, updates the XML, and returns the updated XML using the DOMDocument's xml property.

The source XML string contains the XML declaration line (<?xml version='1.0' encoding='UTF-8'?>), with the encoding attribute. But the updated XML does not contain the encoding attribute. After doing some research on this, I found out that since DOMDocument xml property is a BSTR (Unicode), it always returns Unicode string after stripping the encoding attribute. I understand that the DOMDocument save method preserves the encoding attribute, but I want to avoid saving the XML document, just to preserve the encoding attribute.

Is there any other way to preserve the encoding attribute when the function returns the updated XML text? (12/15/2002) (Viewed 2722 times)
Question 84: I am using MSXML ServerXMLHTTP object to send a request to an ASP page on some remote server; and then use responseText property to get the returned data from the ASP page. Now if the ASP page returns any special characters, the responseText converts them to question mark (?) characters. (12/7/2002) (Viewed 2181 times)
Question 83: I am submitting a form using XMLHTTP component in a JScript code inside a HTML Web page. However, if the form data contains Euro symbol (), then the page to which the POST request is sent, does not receive the symbol as it is. Can you please help? (11/27/2002) (Viewed 1708 times)
Question 82: I have an XML document that contains binary data in the base64 encoded format. I create this binary data node using MSXML and hence it adds the xmlns:dt="urn:schemas-microsoft-com:datatypes" dt:dt="bin.base64" attribute to this binary node.

Now, when I try to validate this XML document using XSD schema, I get the error "The attribute '{urn:schemas-microsoft-com:datatypes}dt' on this element is not defined in the DTD/Schema".

If I remove the xmlns:dt="ur... attribute, the validation succeeds, but then MSXML nodeTypedValue does not recognize the data as binary, it treats it as a string, and hence I am not able to get back the binary data from the base64 encoded value. Is there a way that I can validate the XML document, and still get back the binary node value. (11/22/2002) (Viewed 5872 times)

Question 81: I want to determine the exact version of the XML parser being used by IIS in an ASP page or the file version of the registered DLL. Can this be done? (11/21/2002) (Viewed 3114 times)
Question 80: The XML document load fails if it refers to an external DTD file; however, it succeeds if the DTD is added inline. (11/15/2002) (Viewed 1718 times)
Question 79: I have a .NET Web service that returns a DataSet. This Web service works fine when I call it from a VB.NET client; however I am not able to figure out how to call this Web service from an ASP page and then process the results. (11/14/2002) (Viewed 4027 times)
Question 78: I am using ADO 2.6 to persist/save the recordset in the XML format (adPersistXML). Later on I use MSXML 4.0 to load this XML file and process it. I am using XPath expressions to select nodes, however I don't get back any nodes. Is it something to do with namespace prefixes? (11/12/2002) (Viewed 2383 times)
Question 77: Is it possible to find out line number in the source XML document for any given element? (11/12/2002) (Viewed 1201 times)
Question 76: I am using MSXML 2.0 for basic XML processing in my Visual Basic Application, and it is working fine for me. I chose version 2 instead of 3.0 to keep the installation package size small. To distribute my application, is it sufficient to include MSXML.dll in my installation and make sure to register it? (11/12/2002) (Viewed 1227 times)

Question 75: I am using XSLTemplate and FreeThreadedDOMDocument in my ASP page. The code was working fine, and all of sudden it started failing today with the error
msxml3.dll (0x80070057)
The parameter is incorrect.
 (11/12/2002) (Viewed 2093 times)
Question 74: I am using MSXML to dynamically create a XML document; but am not able to figure out how to create <!DOCTYPE database SYSTEM "database.dtd"> line in the XML document being created. (10/23/2002) (Viewed 3567 times)

Page: 1  2  3  4  5  


Click here to ask a MSXML Question to perfectxml.com Team

  Contact Us | E-mail Us | Site Guide | About PerfectXML | Advertise ©2004 perfectxml.com. All rights reserved. | Privacy