Cannot view XML input using XSL style sheet

senthil
Member Posts: 9
Hi,
I am trying to export a user defined table(created by myself) to a xml file by using XMLPort. I run the code from the codeunit. I used the following code.
TestFile.CREATE('D:\Navision\XMLFile\Import.xml');
TestFile.CREATEOUTSTREAM(TestStream);
XMLPORT.EXPORT(90109,TestStream);
TestFile.CLOSE;
The XML file has successfully created. But the problem is when i opened that XML file in IE it shows the following error
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
A name was started with an invalid character. Error processing resource 'file:///D:/Navision/XMLFile/Import.xml'. Line 3, ...
But i opened the XML file in notepad all data of that table has been exported to the XML File successfully. But in XML FIle i could not seen all the rows. i seen the first row only. Y it has happened like this. And Y this error is coming
I am trying to export a user defined table(created by myself) to a xml file by using XMLPort. I run the code from the codeunit. I used the following code.
TestFile.CREATE('D:\Navision\XMLFile\Import.xml');
TestFile.CREATEOUTSTREAM(TestStream);
XMLPORT.EXPORT(90109,TestStream);
TestFile.CLOSE;
The XML file has successfully created. But the problem is when i opened that XML file in IE it shows the following error
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
A name was started with an invalid character. Error processing resource 'file:///D:/Navision/XMLFile/Import.xml'. Line 3, ...
But i opened the XML file in notepad all data of that table has been exported to the XML File successfully. But in XML FIle i could not seen all the rows. i seen the first row only. Y it has happened like this. And Y this error is coming
Regards,
Senthil
Senthil
0
Comments
-
senthil wrote:Hi,
I am trying to export a user defined table(created by myself) to a xml file by using XMLPort. I run the code from the codeunit. I used the following code.
TestFile.CREATE('D:\Navision\XMLFile\Import.xml');
TestFile.CREATEOUTSTREAM(TestStream);
XMLPORT.EXPORT(90109,TestStream);
TestFile.CLOSE;
The XML file has successfully created. But the problem is when i opened that XML file in IE it shows the following error
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
A name was started with an invalid character. Error processing resource 'file:///D:/Navision/XMLFile/Import.xml'. Line 3, ...
But i opened the XML file in notepad all data of that table has been exported to the XML File successfully. But in XML FIle i could not seen all the rows. i seen the first row only. Y it has happened like this. And Y this error is coming
a.) notepad and wordpad are working different when it comes to the encoding
b.) IE sometimes fails to display even well-formed XML files
Notepad decodes e.g. a UTF-8 file and it looks "pretty", wordpad reads it as a raw format and it looks scrambled because of the special characters.
Therefore, I suggest you'd use a program where you will be able to check the raw data and the decoded separately, e.g. if you use special characters and they are encoded with UTF-8 and you open the file in notpad, it seems to be OK. BUT you do not know, wthether is has been encoded in special encoding format as you will see the decoded result.
Use either a hex editor or real XML editor like XMLSPYTorsten
MCP+I, MCSE NT, Navision MCT (2004,2005)0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions