realbasic-nug
[Top] [All Lists]

Re: Can I, Pretty Please???

To: REALbasic Network Users Group <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Can I, Pretty Please???
From: Didier Barbas <lists at sungnyemun dot org>
Date: Sat, 29 Jun 2002 13:51:51 +0900
  dim flag as boolean
  dim Num as integer
  
  Num=11
  flag=(Num>10)
  
  if flag then
    msgBox "true"
  else
    msgBox "false"
  end if
  
Try it!


-- 
Didier Barbas
Dilettante programmer and linguist
http://ww.sungnyemun.org

On 6/29/02 1:44 PM, "Jim  Wagner" <wagnerj at proaxis dot com> wrote:

> Hello, NUG -
> 
> In C, you can use the boolean result of a conditional expression to assign
> a boolean value. For example, if Flag is declared as a boolean, you can, if
> memory serves correctly (and it might not), write:
> 
> Flag = (Num > 10)
> 
> Granted, the syntax is a bit different, but can you, in RB, write:
> 
> Flag = (Num > 10)
> 
> If not, is it worth a feature request? It would save this structure which I
> have been using over and over in many variations,
> 
> If X > 10 then
> flag = true
> Else
> flag = false
> End
> 
> Jim Wagner



<Prev in Thread] Current Thread [Next in Thread>