Using Python

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • beemer328i2004

    #1

    Using Python

    Hi Guys,

    I am new to this language and i need some help...

    I am trying to create a script that will go into a log file and bring
    me back the xml from an order...

    For example:

    go into Log1.xml and extract order number 2 from top to bottom and
    extract it into a txt file...

    Does anyone know how i can create this type of script or has like a
    sample that i can use.. I am having a hard time starting the script..

    hope someone can help

    Thanks agian

  • hg

    #2
    Re: Using Python

    beemer328i2004 wrote:
    Hi Guys,
    >
    I am new to this language and i need some help...
    >
    I am trying to create a script that will go into a log file and bring
    me back the xml from an order...
    >
    For example:
    >
    go into Log1.xml and extract order number 2 from top to bottom and
    extract it into a txt file...
    >
    Does anyone know how i can create this type of script or has like a
    sample that i can use.. I am having a hard time starting the script..
    >
    hope someone can help
    >
    Thanks agian
    >
    You might want to start here: http://diveintopython.org/

    hg

    Comment

    • Larry Bates

      #3
      Re: Using Python

      beemer328i2004 wrote:
      Hi Guys,
      >
      I am new to this language and i need some help...
      >
      I am trying to create a script that will go into a log file and bring
      me back the xml from an order...
      >
      For example:
      >
      go into Log1.xml and extract order number 2 from top to bottom and
      extract it into a txt file...
      >
      Does anyone know how i can create this type of script or has like a
      sample that i can use.. I am having a hard time starting the script..
      >
      hope someone can help
      >
      Thanks agian
      >
      You should also review this module for parsing your XML:



      elementree is now part of the standard library.

      Note: It would also help if you would post contents of log1.xml
      so others could see what you are working with. You should also
      post whatever python code you have tried so far.

      -Larry

      Comment

      Working...