kagehi
Member in Training
Posts: 26
|
Post by kagehi on Jan 24, 2021 19:59:12 GMT
Hmm. Still getting "file handle invalid" with:
textbox #Dice.AthDat, 218, 150, 12, 12 print #Dice.AthDat, "7" print #Dice.AthDat, "!disable"
I need to be able to set the value of the text box, but not have it editable. #Dice is the window itself, so.. No idea why this won't work.
|
|
|
Post by Rod on Jan 24, 2021 20:08:32 GMT
Well you can easily disable a textbox, Windows displays bmps no matter what the input format. Often you want to access the bmp anyway. The new memory limit is 256mb.
nomainwin
textbox #dice.txt1, 20, 40, 260, 25 textbox #dice.txt2, 20, 70, 260, 25 WindowWidth = 350 : WindowHeight = 190 open "Simple text box use" for dialog as #dice #dice "trapclose [quit]"
#dice.txt1 "I am disabled" #dice.txt1 "!disable" #dice.txt2 "I am not disabled" wait
[quit] close #dice end
|
|
|
Post by tsh73 on Jan 24, 2021 20:12:23 GMT
Hmm. Still getting "file handle invalid" with: textbox #Dice.AthDat, 218, 150, 12, 12 print #Dice.AthDat, "7" print #Dice.AthDat, "!disable" I need to be able to set the value of the text box, but not have it editable. #Dice is the window itself, so.. No idea why this won't work. In JB you first describe controls (textbox #Dice.AthDat, 218, 150, 12, 12) Then you open window, and they get created (open "Simple text box use" for dialog as #dice) AFTER THAT you could work with them (put text there, enable/disable, etc)
|
|
kagehi
Member in Training
Posts: 26
|
Post by kagehi on Jan 24, 2021 20:18:06 GMT
Ok.. So, is the problem that I used "window" as the window type, but I need to be using "dialog"? EDIT: Ok, no, looking at the docs, this can't be the issue...
... textbox #Dice.AthDat, 218, 150, 12, 12 print #Dice.AthDat, "7" print #Dice.AhtDat, "!disable" ...
Open "Vinder" for window as #Dice print #Dice, "trapclose [Exit]" [waitit] wait goto [waitit]
[Exit] end
...
On a minor side note.. Using a tablet computer and.. the number of times I have accidentally brushed my fingers over the "touch pad" and somehow copied and pasted over code, or tapped the "fn" key, which they placed right where my hand expects the bloody left ctrl to be... Sigh.. lol
|
|
|
Post by Rod on Jan 24, 2021 20:24:05 GMT
Type "window" will do just fine. But you need to open the window before you try and send it commands. Reposition your print 7 and disable commands lines.
Don't know where you picked up [waitit] goto [waitit] but they are completely unnecessary WAIT will do ok on its own.
So open the resource, send it commands then wait for the next event that will drag you away from wait.
|
|
kagehi
Member in Training
Posts: 26
|
Post by kagehi on Jan 24, 2021 20:36:19 GMT
Ah.. Ok. I see. That makes... sort of sense. Thanks.
|
|
kagehi
Member in Training
Posts: 26
|
Post by kagehi on Jan 24, 2021 20:39:34 GMT
Without creating a loop there it kept, once and event happened, falling through to the "exit" code. Also, since I was having an issue with something else, it gave me the means to execute something some place else, then pop back to the loop. Will experiment on why this is happening, later, maybe, when I finally do some restructuring and code clean up. For now, it works, and I don't want to break things that are working. lol
|
|
kagehi
Member in Training
Posts: 26
|
Post by kagehi on Jan 24, 2021 20:52:30 GMT
Right, never mind on that last one. Found "statictext". lol
|
|
|
Post by xxgeek on Jan 25, 2021 23:03:46 GMT
I suggest reading the entire help file from top to bottom, more than once,... Yeah and to learn a language just read the English to xLanguage, twice! ha, ha, ha that's funny. Did you read the Help file twice? Seriously, it does help to learn the Help file structure though. Well, I can see why you took my suggestion the wrong way. Forum texting does that at times. I should have worded that line differently, oh well. Sorry to have come across so arrogant. Back a few years the phrase RTFM was thrown at me so often I changed my ways lol Yes, I have read the entire help file more than twice from top to bottom. And each time I read it, I gain new insight as to the syntax and structure of JB programming, and the editors structure. As I reread I have an editor opened to save specifics to for easy reference. I would suggest that too, but don't want to be here all day explaining my arrogance I am getting very close to posting an app I have created and it would not have been possible had I not read the help files, and a few other files (some mentioned already) I could have gone a different route and came to these forums asking questions non stop on a daily (maybe hourly) basis for a month or so Hey B+, it's all good. Thanks for pointing it out, really. I didn't mean to come across as an arrogant sob and will check myself in future. If you see me do it again, please make mention. Actually I am quite tolerant, and more of a clown in real life. Life is too short, and we'll all be dead one day soon enough. peace out
|
|
|
Post by B+ on Jan 26, 2021 1:07:28 GMT
I suggest reading the entire help file from top to bottom, more than once,... Yeah and to learn a language just read the English to xLanguage, twice! ha, ha, ha that's funny. Did you read the Help file twice? Seriously, it does help to learn the Help file structure though. Well, I can see why you took my suggestion the wrong way. Forum texting does that at times. I should have worded that line differently, oh well. Sorry to have come across so arrogant. Back a few years the phrase RTFM was thrown at me so often I changed my ways lol Yes, I have read the entire help file more than twice from top to bottom. And each time I read it, I gain new insight as to the syntax and structure of JB programming, and the editors structure. As I reread I have an editor opened to save specifics to for easy reference. I would suggest that too, but don't want to be here all day explaining my arrogance I am getting very close to posting an app I have created and it would not have been possible had I not read the help files, and a few other files (some mentioned already) I could have gone a different route and came to these forums asking questions non stop on a daily (maybe hourly) basis for a month or so Hey B+, it's all good. Thanks for pointing it out, really. I didn't mean to come across as an arrogant sob and will check myself in future. If you see me do it again, please make mention. Actually I am quite tolerant, and more of a clown in real life. Life is too short, and we'll all be dead one day soon enough. peace out Oh hey, just having a little fun with you! Man if you read Help file twice, I am really really impressed. Really not arrogance when it's the truth. I look forward to seeing your coding efforts. I love the enthusiasm you are showing!
|
|
|
Post by xxgeek on Jan 26, 2021 1:34:01 GMT
Hey A- err, I mean B+
PM sent
|
|