By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,848 Members | 1,290 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,848 IT Pros & Developers. It's quick & easy.

Accessing Xml File Through Perl And Running It In Telnet

P: 5
I have ten xml files (each xml file is executed in batch or telnet using the command (say) xyz.xml1, xyz.xml2 in batch !)

Now instead of executing each and every xml every time , i have to write a code in perl where it will access the ten xml files , run the xml one by one and produce the output in telnet or in batch !

please help me!
Feb 23 '08 #1
Share this Question
Share on Google+
3 Replies


numberwhun
Expert Mod 2.5K+
P: 3,503
I have ten xml files (each xml file is executed in batch or telnet using the command (say) xyz.xml1, xyz.xml2 in batch !)

Now instead of executing each and every xml every time , i have to write a code in perl where it will access the ten xml files , run the xml one by one and produce the output in telnet or in batch !

please help me!
Well, being this is a learning forum, we would like to see what code you have tried thus far. Please share it with us, enclosed in the proper code tags, and we will help you from there.

Regards,

Jeff
Feb 23 '08 #2

P: 5
Well, being this is a learning forum, we would like to see what code you have tried thus far. Please share it with us, enclosed in the proper code tags, and we will help you from there.

Regards,

Jeff


for eg: i have a n xml file (for folder creation)

xml code:

Expand|Select|Wrap|Line Numbers
  1. <CREATE-FOLDER>
  2. <PATH-ELEMENT>abc</PATH-ELEMENT>
  3. <FOLDER-NAME>def</FOLDER-NAME>
  4. </CREATE-FOLDER>
saving it as folder.xml

this xml is in c:\My Documents

now through perl i have to gte folder.xml and run it in (cmd prompt) c:\>My Document(path) \folder.xml

just help me how to link from perl to acees an xml and run it in command prompt or in batch
Feb 23 '08 #3

numberwhun
Expert Mod 2.5K+
P: 3,503
for eg: i have a n xml file (for folder creation)

xml code:

Expand|Select|Wrap|Line Numbers
  1. <CREATE-FOLDER>
  2. <PATH-ELEMENT>abc</PATH-ELEMENT>
  3. <FOLDER-NAME>def</FOLDER-NAME>
  4. </CREATE-FOLDER>
saving it as folder.xml

this xml is in c:\My Documents

now through perl i have to gte folder.xml and run it in (cmd prompt) c:\>My Document(path) \folder.xml

just help me how to link from perl to acees an xml and run it in command prompt or in batch
First, I did request that you use the code tags that eWish had to edit your post with. If you see the sticky in this forum, you would have found out how to use them.

Second, to execuse something on the system, just use the system() function.

Expand|Select|Wrap|Line Numbers
  1. system(/path/to/folder.xml);
  2.  
Regards,

Jeff
Feb 23 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.