Announcement

Collapse
No announcement yet.

stdout text manipulating

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • stdout text manipulating

    I would like to know how to accomplish the following with native command line (not scripting).
    Windows Server 2003 Built in commands , without installing any resource kit or any 3rd party application or util. only through built in commands.

    1) Print X rows from start of the display (stdout)
    2) Print X rows from end of the display (stdout)
    3) Print The X column only of the display (stdout)
    The rules DO apply to me.

  • #2
    Re: stdout text manipulating

    Originally posted by igoldman View Post
    I would like to know how to accomplish the following with native command line (not scripting).
    What are you trying to achieve with that kind of limitations anyway? Strictly speaking, batch files are scripting solutions too.

    You could redirect output into a file, load it with notepad and edit / print what you need. For added complexity, please take a few drinks, close your eyes and type with left hand only

    -vP

    Comment


    • #3
      Re: stdout text manipulating

      igoldman,
      Read Rule #10 about live links in the signature.!
      And keep it in English please.

      \Rems

      This posting is provided "AS IS" with no warranties, and confers no rights.

      __________________

      ** Remember to give credit where credit's due **
      and leave Reputation Points for meaningful posts

      Comment


      • #4
        Re: stdout text manipulating

        Originally posted by Rems View Post
        igoldman,
        Read Rule #10 about live links in the signature.!
        And keep it in English please.

        \Rems
        Hi

        My Join Date: Sep 2004

        Respect !!! The new rule was not part of the forum rules when I joined the forum in 2004.
        Since that , I don't need to be limited.

        Originally posted by vonPryz View Post
        What are you trying to achieve with that kind of limitations anyway? Strictly speaking, batch files are scripting solutions too.

        You could redirect output into a file, load it with notepad and edit / print what you need. For added complexity, please take a few drinks, close your eyes and type with left hand only

        -vP
        I would like to make a script which is based on manipulating stdout text.
        I don't want to write th output into a text file. I try to accomplish an opration which will use minimal resources.
        The rules DO apply to me.

        Comment


        • #5
          Re: stdout text manipulating

          Originally posted by igoldman View Post
          I would like to make a script which is based on manipulating stdout text.
          What exactly do you mean by stdout in this context? The command prompt window (=the black box thing)?

          I don't want to write th output into a text file.
          Fair enough. You got some application that writes stuff into stdout, like this:

          std::cout << "Here is a C-string to stdout!" << std::endl;

          Unless you got a source access and are able to modify the app, it is going to write into stdout. You can not read from another process' stdout unless some tricks are made in the application (dup2() and popen() come into my mind), so your best bet is to redirect the output and process it. The easiest way is to redirect into a file and process it. Or you could pipe the output to another a program and manipulate the output there - which obviously requires way more programming you'd like to do.


          I try to accomplish an opration which will use minimal resources.
          Minimal resources, eh? Is the situation so that you are not allowed to install any third-party tools to the system you intend to use? If this is the case, are you aware that VBScript is a software that is a part of Windows OS install? Powershell is available only as a separate download, save Server 2k8. If not, what do you mean by minimal resouces? You want the best performance, minimal memory consumption, highest throughput..?

          Unless you tell me more details on what you are trying to achieve, I really can't help you too much.

          -vP

          Comment


          • #6
            Re: stdout text manipulating

            Originally posted by igoldman View Post
            Hi

            My Join Date: Sep 2004

            Respect !!! The new rule was not part of the forum rules when I joined the forum in 2004.
            Since that , I don't need to be limited.
            If you think you stand above the forum rules then you are wrong.
            You don't impress me with 28 posts in about 5 years.

            Adapt the forum rules as they currently are.
            Marcel
            Technical Consultant
            Netherlands
            http://www.phetios.com
            http://blog.nessus.nl

            MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
            "No matter how secure, there is always the human factor."

            "Enjoy life today, tomorrow may never come."
            "If you're going through hell, keep going. ~Winston Churchill"

            Comment


            • #7
              Re: stdout text manipulating

              Rule adoption enforced. If it is changed back to something unacceptable there will be consequences.

              You have disrespected the Site, the Forum, the members and Daniel. Please do not do this again. Thank you.
              1 1 was a racehorse.
              2 2 was 1 2.
              1 1 1 1 race 1 day,
              2 2 1 1 2

              Comment

              Working...
              X