|
-
Jul 3rd, 2001, 05:07 PM
#1
Thread Starter
Frenzied Member
Getting 1 character from a text box
I can get a string, but I've never tried numbers, so right now Im trying a single number that is only one digit long. Thanks
-
Jul 3rd, 2001, 05:10 PM
#2
Monday Morning Lunatic
If it's a dialogue, use GetDlgItemInt . If a window, use GetWindowText and then atoi to convert the text.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 3rd, 2001, 05:14 PM
#3
Thread Starter
Frenzied Member
Ever time I do (GetWindowText) I get 0.
Code:
x = GetWindowText(GetFrom1, buff, 5);
x = atoi(buff);
-
Jul 3rd, 2001, 05:16 PM
#4
Monday Morning Lunatic
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 3rd, 2001, 05:18 PM
#5
Thread Starter
Frenzied Member
never mind, it works all of a sudden thanks
-
Jul 3rd, 2001, 05:19 PM
#6
Monday Morning Lunatic
Oooops I got a tad confused as well - did you change to the code you have now?
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Jul 3rd, 2001, 05:31 PM
#7
Thread Starter
Frenzied Member
yeah I was editing it while posting and I forgot to finished editing it....sorry
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|