Sign in to follow this  
Followers 0
Jeaux

Question about Input

4 posts in this topic

Hello All, here's what I need some help with:

Case $button3

$input1 = inputbox ("CD/DVD Drive", "")

$input2 = inputbox ("File Path", "")

runwait (@comspec & " /c " & "echo $input1 $input2 > test.txt", "", @SW_HIDE)

I need to take user input and add it to the command line. The text file that is made has $input1 $input2. How do I get it to use the actual input?

This might be a very easy question, but I have researched for a long time on different ways to get this done. Any help would be welcomed.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Use GUICtrlRead($input1) respectively GUICtrlRead($input2) to read input line.

Edit: Ops, did not read carefully. GUICtrlRead() is only for GUICtrlCreateInput()!

Br,

UEZ

Edited by UEZ

Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯  ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ

Share this post


Link to post
Share on other sites

in your current example you have to remove the quotes around the variables so they are not treated as literal strings:

$input1 = inputbox ("CD/DVD Drive", "")
$input2 = inputbox ("File Path", "")

runwait ("cmd /c " & "echo " & $input1 & $input2 & " > c:\testPIPING.txt", "", @SW_HIDE)

run ("notepad c:\testPIPING.txt")

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

works like a champ! Thanks!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0