cancel
Showing results for 
Search instead for 
Did you mean: 

Get string from CMD

felipedantasvit
Level 2
I have an object that executes a CMD command but I also need to capture a string that appears after the command is executed

For example:
36216.png
Get the string "Nome do host: CSCN-1156"

Is there any way to do this?
1 BEST ANSWER

Helpful Answers

KotaSuto1
Level 5
Hi,

Would you try the way below?

Note: If invalid params are set to "Arguments", There is a risk that Blue Prism Interactive Client will freeze.

1. Set an Action Stage.
2. Select "Utility - Environment" object and "Start Process Read Stderr and Stdout" action.
3. Configure blow params: 
    - Arguments: /C "<command that you want to execute>"
    - Process Name: cmd
4. Set an Data Item to "Standard Output", output param.

View answer in original post

4 REPLIES 4

KotaSuto1
Level 5
Hi,

Would you try the way below?

Note: If invalid params are set to "Arguments", There is a risk that Blue Prism Interactive Client will freeze.

1. Set an Action Stage.
2. Select "Utility - Environment" object and "Start Process Read Stderr and Stdout" action.
3. Configure blow params: 
    - Arguments: /C "<command that you want to execute>"
    - Process Name: cmd
4. Set an Data Item to "Standard Output", output param.

felipedantasvit
Level 2
I dont know why but i dont have the action "Start Process Read Stderr and Stdout" action in my Environment Utility. How do i get this?

KotaSuto1
Level 5
What is your Blue Prism version now?
If I remember correctly, the action has is introduced since v6.3 onward.

When you are using older versions, you'd consider to upgrade the version.
Otherwise When you are using newer versions, you'd re-import the VBO.

If the problem isn't still solved, you'd ask Customer Support Team to provide the VBO.
(I can tell you the codes of the action, but they have a possibility of differences in each versions.)

felipedantasvit
Level 2
Thank you Kota Suto, i am waiting for my team to re-import the VBO, I´ve read about this Action and it will probably solve my problem.