SkysLastChance Posted January 26, 2017 Posted January 26, 2017 (edited) Okay so I am not sure if I can do this or not with the code I currently have but, I would like to send lastname and the first name with a comma inbetween. so it would look like "last name,first name" right now I just have it sending the last name. any help or sugestions are appreciated. $r = 1 Local $aArray = _Excel_RangeRead($oExcel, Default, Default) For $i = 1 To UBound($aArray) - 1 ;$i =0 Start from row A $sR1 = $aArray[$i][0] ;status $sR2 = $aArray[$i][1] ;first name $sR3 = $aArray[$i][2] ;Last name $sR5 = $aArray[$i][5] ;Email Address WinWaitActive ("[CLASS:MGUIWin]") Sleep (100) ControlSend("[CLASS:MGUIWin]", "", "Edit2", $sR3, & @CR) $r = $r + 1 If $r > $sBox Then Exit Endif Next Edited January 30, 2017 by SkysLastChance Clean up code You miss 100% of the shots you don't take. -Wayne Gretzky -Michael Scott
Subz Posted January 27, 2017 Posted January 27, 2017 Why not just use the Array for example ControlSend("[CLASS:MGUIWin]", "", "Edit2", $aArray[$i][1] & ',' & $aArray[$i][2] & @CR) SkysLastChance 1
SkysLastChance Posted January 27, 2017 Author Posted January 27, 2017 Just for refrence I went with this. ControlSend("[CLASS:MGUIWin]", "", "Edit2", $sR3 & ',' & $sR2 & @CR) Thank you subz, I swear I tried this but, I must of forgot a "&" after the comma or something. You miss 100% of the shots you don't take. -Wayne Gretzky -Michael Scott
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now