Re: Liberty Basic?



On Mar 15, 3:10 pm, "dajava" <daj...@xxxxxxxxxxxxx> wrote:
For example, I want to get two numbers from screen,
add them, and display summation of them on screen.

-----Windows munu ---------

Num 1 = Num2 =
Sum =

-------------------------

Any hints for this?

I'm sure somebody will post the LB code, but for comparison here's how
it's done in BBC BASIC:

INSTALL @lib$+"WINLIB2"
dlg% = FN_newdialog("Windows adder", 0, 0, 160, 50, 8, 1000)
PROC_static(dlg%, "Num 1 =", 0, 10, 10, 30, 12, 0)
PROC_static(dlg%, "Num 2 =", 0, 80, 10, 30, 12, 0)
PROC_static(dlg%, "Sum =", 0, 10, 30, 30, 12, 0)
PROC_editbox(dlg%, "", 101, 44, 8, 30, 12, 0)
PROC_editbox(dlg%, "", 102, 114, 8, 30, 12, 0)
PROC_editbox(dlg%, "", 103, 44, 28, 30, 12, 0)
PROC_showdialog(dlg%)

REPEAT
SYS "GetDlgItemInt", !dlg%, 101, 0, 1 TO num1%
SYS "GetDlgItemInt", !dlg%, 102, 0, 1 TO num2%
SYS "SetDlgItemText", !dlg%, 103, STR$(num1%+num2%)
WAIT 1
UNTIL FALSE

Richard.
http://www.rtrussell.co.uk/
To reply by email change 'news' to my forename.

.



Relevant Pages

  • Efficient evaluation of a Fourier-like sum
    ... values at which I am interested in evaluating S, ... Obviously by brute force I can evaluate the above sum ... Extra points for hints as to a scheme that can be ... replaced by a dot product. ...
    (sci.math)
  • Re: Help check my proof please?
    ... and increasing function. ... required RHS. ... you totally abandoned my hints. ... Sum them up symbolically, not numerically. ...
    (sci.math)
  • Re: (Discrete Math - Induction) Formula Differentiation
    ... ANY hints on how the derivative of the sum of terms of a G.P will get ... problem is from the Mathematical Induction chapter of my Discrete ...
    (sci.math)
  • Re: Help check my proof please?
    ... I understand that this is the sequence until infinity, ... But you have switched back to the first group of hints, where the sum ... the sum is built from the bottom up. ...
    (sci.math)