Process a File String as a Command


New member
Apr 12, 2005
Programming Experience
I have a question thats really hard to explain...
this app I've been working on allows one to connect with a linux box via ssh2 and then send it commands via click of buttons (pre programed)
I now have one string that is stored in a file like this:
(("./screen -s /bin/bash") & (Chr(10)) & (Chr(10)) & ("ls -al") & (Chr(10)) & (Chr(10)) & ("^A") + ("c./newcommand")))
here is the trick part (for me anyhow) I retrieve the string fine as "strCmd", I used Sendkeys.Send (strCmd) ' which is the saved and now retrieved pasted above command.

problem? it prints it to the screen! with the &'s and (chr(10))'s etc...I want it to execute it like a normal line of code...please dont bother with the contents of the string...its alot of explaining but I willl breif (the (Chr(10)) is LineFeed, and the ("^A") is ctrl-a simlutations...long story) but I need the it to execute the strCmd...and I dont want the line hard coded...I have a screen to get/edit/save the string back to a file...
thanks for your help always