I am running this and it gives a strange output. Also, I don't know how to get at the value of a text box from another procedure similar to a call with linkage in the code below. Is anyone out there using this that can give me a pointer? Thanks roboloki
::cobolIDENTIFICATIONDIVISION.PROGRAM-ID.demo.ENVIRONMENTDIVISION.DATADIVISION.WORKING-STORAGESECTION.01alabelusagepointer.01abuttonusagepointer.01atextusagepointer.PROCEDUREDIVISION.invokeSUPER"addform"returningSELF.move"GuiCOBOL TEST "to"caption"ofselfinvokeself"addlabel"using" def"returningalabel.invokeself"addbutton"using"hij"returingabutton.invokeself"addtext"using"abc"RETURNINGatext.move"123"to"text"ofatext.*lineabovedoesn'tseemtowork*itreturnstexwhenIruntheprogramandthatdoesn'tseemrighttome*invokeatext"keydown"using"exitForm".call"exitForm"usingatext.move"blue"to"textcolor"ofalabel.move"yellow"to"backcolor"ofalabel.move"arial"to"font"ofalabel.move"300%"to"fontsize"ofalabel.invokeself"show".invokeSELF"run"stoprun.endprogramdemo.identificationdivision.program-id.exitForm.datadivision.working-storagesection.01out-lengthusagebinary-long.01middlemanpicx(10)based.01replacementpicx(10).linkagesection.01mytextusagepointer.proceduredivisionusingmytext.setout-lengthto3.setaddressofmiddlemantomytext.movemiddleman(1:out-length)toreplacement.displayreplacement.exitprogram.
the program displays text which doesn't seem right - thanks
Last edit: Simon Sobisch 2020-10-16
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Can you please check if it is possible for you to register/login? That removes the additional moderation work a human would otherwise have to do and also provides instant posts and optional notifications.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
HI all-
I am running this and it gives a strange output. Also, I don't know how to get at the value of a text box from another procedure similar to a call with linkage in the code below. Is anyone out there using this that can give me a pointer? Thanks roboloki
the program displays text which doesn't seem right - thanks
Last edit: Simon Sobisch 2020-10-16
Can you please check if it is possible for you to register/login? That removes the additional moderation work a human would otherwise have to do and also provides instant posts and optional notifications.
Hi Simon-
Yes, I went in and upated account settings at Sourceforge.
I am very excited to study COBOL. I was off on a tangent studying U++ , tigervnc, SSH, gpg, etc.
I hope you and Brian are having a cool weekend.
I will keep a low profile this weekend.
thanks
roboloki
Maybe you should declare the atext external
01 atext usage pointer external.
and the obtain the value
move "text" of atext to stringa.
display "here the value:" stringa.
where the stringa is declared in your exitForm procedure
into the working storage section.
Federico
Hi Federico-
Sorry about tthe delay in getting back to you. I did not feel well this past week. I am back though.
It is a very good tip you gave me!
thanks,
roboloki
This code has not been through a compiler because the 3rd invoke line has a typo, I gave up reading the code at that point.
You say something doesn't seem right, what did you expect instead?
Hi-
Federico knew right away what I was expecting. See his comment about using usage pointer external.
thanks.