Saving an XML File
If I try to save a file (well-formed xml) with the extension of .xml through NTFS protocol I get an error. Same xml file but with a .txt extension is saved fine. This file is created with Notepad. Using Win2000 and iFS1.1. Thanks for any help.
Error is: H\TestSearch.xml
The file is on a network drive with create but no modified privileges.
Ask the administratorof this network to change this condition.
null
<?xml version="1.0"?>
<docs>
<doc id="222">
<name>HB123.xml</name>
<folder>/BillDrafting/ga92/Drafts</folder>
<owner>John Doe</owner>
<lastMod>02/05/2001</lastMod>
</doc>
</docs>
No dtd, no custom class.
Similar Messages
-
Saving the XML File in Unix Filesystem
Hello,
Please let me know,
1) i have generated a XML File, Is there any Function Module to save the XML file in Unix File System .
2) How to send the XML file to a NON-SAP System using FTP Transfer .
Regards,
jvs
Edited by: jvsvijay on Dec 6, 2011 9:51 AM
Moderator message: please search for available information/documentation.
Edited by: Thomas Zloch on Dec 6, 2011 2:23 PMHi,
What I have done in the past, and seems to work, is execute an Interface or Procedure in simulate mode, choosing the agent that you would like to use in reverse engineering the XML. Then, attempt to reverse engineer the file again. Not sure if this will work, but it has for me at times. You might also try this and restarting ODI to clear out anything 'cached' in the JVM.
It seems ODI is caching the agent that you are using - but I'm not sure how to properly change it.
Regards,
Michael Rainey -
Saving an xml file in local machine(urgent)
Hi Techies,
I am creating the xml file from jsp and generation of xml is working fine for me.
Now the query is How can I point out the location of local machine??
Here is my code
String locationAndBackupFileName =request.getParameter("locationAndNameOfBackupFile");
System.out.println("Location"+locationAndBackupFileName);
StringWriter stringOut = new StringWriter();
XMLSerializer serial = new XMLSerializer(stringOut, new OutputFormat("xml", "UTF-8", true));
response.setContentType("application/xml");
response.setHeader("Content-Disposition","attachement; filename="+locationAndBackupFileName);
serial.setOutputCharStream(new FileWriter(locationAndBackupFileName));
serial.serialize(document.getDocumentElement());when I xcute my code I am getting download dialog box, with save option.
But after downloading no data is available.
Can u guys help me to fix this problem
regards,
krishI don't know what you mean by "location of local machine". The response is being sent to a client machine (maybe that's your "local" machine). You have a lot of strange code that looks like it's serializing the XML to various places, but it should be serializing it to the response's output stream if you want it to go to the client.
There is no way for you, on the server, to control where on the client machine the response data will be stored. That is entirely up to the user on the client. And you certainly can't write it to the client without the knowledge and consent of the client. That's just basic network security. -
Saving as XML file from Report
Hi All,
How to convert a Data's in a custom table to output in XML format n store in a FTP folder by runnig a report in ABAP. That is each time when a custom report is run the data's which gets populated into a custom table shuld also be generated as output in XML format and get saved in a FTP folder.
Already some of the friends hav given suggestions but i need more information and a clear idea pls don't mistake me.
we are using version mySAP ECC 5.0, n how to use Call transformation and the FM 'HR_EFI_CONVERT_STRING_TO_TABLE'is not avilable in version 4.7 Entprise Edition.
Is there any Function Modules or standard reports avialable for this scenario.Pls do help
Suggestion and Help will be much appreciated.
Thanks & Regds.
Ramesh.let me understand.
when you say custom table do you mean a data base table?
check out this code sample of a FM
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f50dcd4e-0501-0010-3596-b686a7b51492
which takes any DB table name as input along with where conditions and returns the result as xml.
once you get the xml to put it in a FTP server, you can use the code specified in this weblog.
/people/thomas.jung3/blog/2004/11/15/performing-ftp-commands-from-abap
Regards
Raja -
How to update XML file from the program
i am new in abap , and i have the following issue,so plz anyone who knows how to do it
Background :
An XML file is used as the datasource for a Flex Application. From time to time this requires updating with new staff details.
i have already saved the xml file in the c drive with the name C:\AdvAC\AC1\bin-debug\assets\staff
Requirement : Write a Dialog transaction with the following text input fields.
Reference Indicator. (Char10)
Staff No (NUMC, Length 5)
Name (Char50)
Room (Numc, length 3)
Phone (Numc Length 7)
Mail (char30)
in screen 100
The transaction should also have an u201CUpdate Fileu201D button, which when pressed :
1) Loads the file C:\AdvAC\AC1\bin-debug\assets \ into an ITAB.
2) Inserts the data into the ITAB using the following XML format.
<staff>
<ref_ind> Reference Indicator.</ref_ind>
<staff_no> Staff No </staff_no>
<name> Name </name>
<room> Room </room>
<phone> Phone </phone>
<mail> Mail </mail>
</staff>
all should be inside <allstaff> </allstaff> tagsu2026.
Writes the ITAB back to the file.
thanx allthis is what i have done but i dont know how to do the rest. i will apprecite any help from u.
Edited by: man700s on Feb 16, 2010 6:58 AM
REPORT Z_XML_FILE_UPDATE.
TYPES: BEGIN OF ts_staff,
REF_IND(10) TYPE c,
Staff_No(5) TYPE c,
Name(50) TYPE c,
Room(3) Type n,
Phone(7) Type n,
Mail(30) Type c,
END OF ts_staff.
DATA: t_staff TYPE TABLE OF ts_staff WITH HEADER LINE.
DATA: w_staff Type ts_staff.
DATA T_STRING TYPE TABLE OF STRING.
DATA W_STRING TYPE STRING.
call SCREEN 100.
PERFORM upload_xml_file.
PERFORM update_xml_tab.
*PERFORM download_xml_file.
MODULE USER_COMMAND_0100 INPUT.
W_STRING = '<allstaff>'.
APPEND w_string to t_string.
loop at t_staff into w_staff.
w_string ='<staff>'.
APPEND w_string to t_string.
if T_staff-Ref_Ind = 'X'.
CONCATENATE '<Ref_Ind>' w_staff-Ref_Ind '</Ref_Ind>' into w_string.
APPEND w_string to t_string.
ENDIF.
if T_staff-staff_no = 'X'.
CONCATENATE '<staff_no>' w_staff-staff_no '</staff_no>' into w_string.
APPEND w_string to t_string.
ENDIF.
if T_staff-name = 'X'.
CONCATENATE '<name>' w_staff-name '</name>' into w_string.
APPEND w_string to t_string.
ENDIF.
if T_staff-room = 'X'.
CONCATENATE '<room>' w_staff-room '</room>' into w_string.
APPEND w_string to t_string.
ENDIF.
if T_staff-phone = 'X'.
CONCATENATE '<phone>' w_staff-phone '</phone>' into w_string.
APPEND w_string to t_string.
ENDIF.
if T_staff-mail = 'X'.
CONCATENATE '<mail>' w_staff-mail '</mail>' into w_string.
APPEND w_string to t_string.
ENDIF.
w_string = '</staff>'.
append w_string to t_string.
ENDLOOP.
W_STRING = '</allstaff>'.
APPEND w_string to t_string.
ENDMODULE.
Edited by: man700s on Feb 16, 2010 7:01 AM -
Hi guys,
I'm having quite simple task, but no idea how to achieve it. A have a While loop, inside it I have som form to fill in and the output of this form is saved into xml file (using older MSXML library) and OK button for running parser and writting data into right place in XML file. All I need to do is to save XML file after the Stop button is hit, or after e.g. five minutes of application run. Just simple autosave feature.
For better ilustration, please see picture, or example.vi file.
I am running LV 2012
Thank you for your answers.
Attachments:
Example.vi 9 KBYou could put these functions in an event structure within the loop. Have a shift register on the loop, passing the value through the various states of the event stucture. Have the "save" button trigger an event to save your data, and at the same time (bad pun) put the current millisecond timer value onto the shift register. In the time out case of the event structure (with a time out value of, say, 100mS wired to it to cause the timeout case to trigger regularly), compare the value of the shift register with the current millisecond count and when enough time (x) has passed have it: 1) put the new time count on the shift register, 2) save the file. This should ensure that the file is saved every x within a 100mS window of time error.
Putnam
Certified LabVIEW Developer
Senior Test Engineer
Currently using LV 6.1-LabVIEW 2012, RT8.5
LabVIEW Champion -
How to add bookmarks from .xml file?
I switched from a PC to an iMac and i'm trying to set up the Safari browser. I was using MSN explorer as my default. I saved the .xml file where all my bookmarks were stored. Is there a way I can import the .xml file so all my bookmarks can load?
hi,
check out the following links
Check this blog to extract from XML:
/people/kamaljeet.kharbanda/blog/2005/09/16/xi-bi-integration
http://help.sap.com/saphelp_nw04/helpdata/en/fe/65d03b3f34d172e10000000a11402f/frameset.htm
Check thi link for Extract from any DB:
http://help.sap.com/saphelp_nw04s/helpdata/en/58/54f9c1562d104c9465dabd816f3f24/content.htm
regards
harikrishna N -
Writing to XML files need help
Guys,
I need to pull out data from the database and write it to multiple flat files in XML.
I can't do it on the database server using utl_file, I need to do it on the client.
Can you tell me the best way to achieve it.
I am giving you a sample plsql that we have built.
I have to create one file for each deptno.
Your values suggestions/inputs would be appreciated.
Dhiren
declare
queryCtx dbms_xmlquery.ctxType;
cursor c1 is select * from dept;
result clob;
begin
for c1rec in c1
loop
queryCtx := DBMS_XMLquery.newContext('select .... from emp where deptno = c1.deptno');
result := DBMS_XMLquery.getXML(queryctx);
DBMS_XMLquery.closecontext(queryctx);
end loop;
end;use the above pl/sql to generate xml.
next step would be to create a folder on the xmldb repository.
this has to be done with SYS user.
DECLARE
l_success BOOLEAN := FALSE;
l_resourceURL resource_view.any_path%TYPE := '/public/scott';
BEGIN
IF (NOT DBMS_XDB.EXISTSRESOURCE(l_resourceURL)) THEN
l_success := DBMS_XDB.CREATEFOLDER(l_resourceURL);
COMMIT;
END IF;
END;
/so now you have your folder as /public/scott under which you can create resources.
resources in XMLDB is nothing but files.
so the generated xml can be saved as xml file under the above path.
to create a resource, you need xmldata and the resource name.
eg.
dbms_xdb.createresource('/public/scott/myxml.xml', l_xml_data);
commit;
now you can ftp the resource to the client,
open <server name> 2100
user scott tiger
get /public/scott/myxml.xml c:\temp\myxml.xml
close
bye
that's it.
good luck.
check the port of the ftp . normally by default it is 2100 unless it is changed by your admin, -
Hi,
I would like to load a xml file with the xml.loader action block.
The name of the file is 78b39221#11b6f.
When i test the transaction i get the error:
[ERROR]: Unable to complete requested action on XML document. c:\Inetpub\wwwroot\Test\78b39221 (The system cannot find the file specified)
How can I manage it to load the file?Torben,
I guess you are working with MII 11.5?
I have just tried it with MII 12.0, saved a XML file with the same name you have mentioned in a WEB folder, and the XML Loader could input the file, no matter if the ".xml" extension was included or not. The xml structure and contents have been read correctly.
Maybe this is a version 11.5 problem, that the suffix "#..." is cut off from the filename so MII could not find the file?
Michael -
How to save infopath form in XML file
How to save InfoPath form in XML file.
I want every new record in InfoPath form save in XML file and also retrieve these records from XML like databasesHi,
Based on your description, my understanding is that you want to save InfoPath form in XML file.
I have done a test in my SharePoint, Do the following steps:
Create an form library and publish an InfoPath form into it, Then when we create new document into the form library, it is by default that InfoPath form is saved in XML file.
Best Regards,
Lisa Chen
Lisa Chen
TechNet Community Support -
Premiere pro not opening xml files
Hi Everyone,
We are transitioning from Final Cut Pro 7 into Adobe Premiere Pro CC. I have exported all my FCP projects as XML Files. I saved the XML files to an external harddrive that I am using to import files into PP on a PC. When I imported the XML files into PP, I was not able to access any files at all in the project. After looking online for answers, it occurred to me that I would need to backup all the source files along with the XML files.
I am in the process of identifying those source files and copying them to the external harddrive that i will be using to edit on Adobe Premiere Pro. The previous videographer did a shoddy job of organizing files, and I am noticing that some projects and their related scratch disks are often in different locations (different Harddrives, some on the original Mac harddrive). In an effort to keep to make our transition to Premiere Pro as painless as possible, I am backing up all NLE related files (render files, capture scratches, source media files, etc) onto one Harddrive. Is this all necessary?
Is there any blog or article online that i can reference on how to transition from FCP7 to Premiere Pro that addresses source material that is spread out on many storage devices?Hi Mike,
mikebcss wrote:
Is there any blog or article online that i can reference on how to transition from FCP7 to Premiere Pro that addresses source material that is spread out on many storage devices?
Not really, Just know that in FCP, you can move media to a single location using the Media Manager. Once media is moved, a FCP XML file will point to that that drive when opened in Premiere Pro.
Hope that helps,
Kevin -
I saved docs from a iMac to a flashdrive but when I plug the flashdrive into an iBookG4 and try to open the docs on the flashdrive, I get this message: Doc 2 cannot be opened. The required index.xml file is missing. Does this mean that I can't use the info on the flashdrive with the iBookG4 or can I do something to get the required index.xml file?
Thanks
jtIt appears if you write the document with newer version Pages and try to open it older version Pages.
-
Error while saving the FM8 XML file
Hello,
While saving the FM8 XML file, an error message appears (see attached screen shot).
Is there a solution to resolve this issue? Please suggest.Hi,
This type of error is non-descript and could be caused by any number of things. It is impossible to troubleshoot from here based solely on that message. Let me ask a couple of questions, though:
- Are you using structured FrameMaker? If so, are you using a structured app that has worked successfully before? In other words, did this just suddenly start happening to an otherwise-stable process?
- Is there anything unusual about your layout; that is, anything other than a single text flow with graphics?
Russ -
Error while saving xml file using PDFDocument API
Hi,
I am trying to save xml file using byte array obtained from interactive form element in webdynpro java.
The file gets saved but I get fllowing error message when I open the file.
The XML page cannot be displayed
Cannot view XML input using style sheet. Please correct the error and then click the Refresh button, or try again later.
An invalid character was found in text content. Error processing resource 'http://uxjciesk.wdf.sap.corp:50000/irj/go/km/doc...
The code I am trying to achieve the functionality is:
byte[] byteArray = wdContext.currentContextElement().getPdfSource();
IWDPDFDocumentHandler pdfDocumentHandler = WDPDFDocumentFactory.getDocumentHandler();
IWDPDFDocumentAccessibleContext documentAccessibleContext = pdfDocumentHandler.getDocumentAccessibleContext();
documentAccessibleContext.setPDF(byteArray);
IWDPDFDocument pdfDocument = documentAccessibleContext.execute();
ByteArrayInputStream dataInputStream = (ByteArrayInputStream) pdfDocument.getPDFAsStream();
further, the datainputstream is used to store the file. I am able to save same xdp template in pdf file format successfully, the error only occurs for xml file storage.
Please, advise.
Regards,
UrvashiHi Urvashi,
Try this code
String contentStr = getXMLData(wdContext.currentContextElement().getPdfSource().read(false));
String data = "";
ByteArrayOutputStream pdfSourceOutputStream = new ByteArrayOutputStream();
try {
InputStream pdfSourceInputStream = wdContext.currentContextElement().getData().read(false);
BufferedInputStream bufferedInputStream = new BufferedInputStream(wdContext.currentContextElement().getData().read(false));
int aByte;
while ((aByte = bufferedInputStream.read()) != -1) {
pdfSourceOutputStream.write(aByte);
pdfSourceOutputStream.flush();
pdfSourceOutputStream.close();
IWDPDFDocument pdfDocument = null;
try {
// Create an instance for PDFDocumnetHandler
IWDPDFDocumentHandler pdfDocumentHandler = WDPDFDocumentFactory.getDocumentHandler();
//Create an Inatance for PDFDocumentAccessibleContext
IWDPDFDocumentAccessibleContext documentAccessibleContext = pdfDocumentHandler.getDocumentAccessibleContext();
//set the pdf data as OutputStream to the PDFDocumentAccessibleContext instance
documentAccessibleContext.setPDF(pdfSourceOutputStream);
//call the server to get the data
pdfDocument = documentAccessibleContext.execute();
//get the xml data in a InputStream
ByteArrayInputStream dataInputStream = (ByteArrayInputStream) pdfDocument.getData();
} catch (Exception e) {
data = "Null";
} catch (IOException e) {
Regards,
Mathan -
I saved a Pages doc yesterday and today I can't open it because I get a message that says "can't open doc because an index.xml file is missing." Help!
Pages v5 documents do not have an internal index.xml file. When you attempt to open one of these with the older Pages '09, you will get that dialog. Double-click the document icon, or right-click, and open with Pages v5 to access the document contents.
Maybe you are looking for
-
Exception during client synchronization in Mobile 7.1
Hello, We are working with Mobile 7.1. We changed one of the records from the client side in the table M45NOTIFICATION (the automatically created table for NOTIFICATION Data Object). During the synchronization with the DOE, the changes passed success
-
Strange sound coming through external speakers
On my 2010 iMac there is a problem when *no audio* is coming out through the external speakers (connected via the headphone port). If i play any sound (even change the volume and get the 'blip' sound) and then go back to silence, after 5 - 10 seconds
-
Do you recommend mac book pro or air?
Do you recommend mack book pro or air?
-
Regd : Amount Verification in F-47
Hi All, Through F-47 , Payment Request is made against a standard PO. The amount in the Payment request is given more than the amount mentioned in the Purchase Order. It is found that the system does not throw any message(error/warning)while posting
-
Installation XE database install
Hi all, i have problem in installing XE 10g database this error appears in dialog at the end of installation: 1608: unable to create installdriver instance, return code -2147221021 i searched for this error in google but i can not find anything relat