Check box in a list box (REALbasic getting started Mailinglist archive)

Back to the thread list
Previous thread: NUG list again
Next thread: Accessing ContextualMenu menu items


RB Database   -   tom.russell transport.alstom.com
  Check box in a list box   -   Barrie Jones
   Re: Check box in a list box   -   Terry Ford
   Re: Check box in a list box   -   Terry Ford
   Re: Check box in a list box   -   Barrie Jones
   Re: Check box in a list box   -   Terry Ford
   Re: Check box in a list box   -   Barrie Jones
   Re: Check box in a list box   -   Terry Ford
   Re: Check box in a list box   -   Barrie Jones
    Re: Check box in a list box   -   D Prowse
     Re: Check box in a list box   -   Charles Yeomans
     Re: Check box in a list box   -   CV
      Re: Check box in a list box   -   D Prowse

Check box in a list box
Date: 09.05.06 03:48 (Mon, 8 May 2006 22:48:14 -0400)
From: Barrie Jones
How do I get checkboxes in a list box? I tried this in the listbox
open event
me.CellType(0,0) Qe.TypeCheckBox
Program runs but it opens the debugger at this line and I don't know
why.
Thanks
Barrie
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 04:36 (Mon, 08 May 2006 20:36:13 -0700)
From: Terry Ford

On May 8, 2006, at 7:48 PM, Barrie Jones wrote:

> How do I get checkboxes in a list box? I tried this in the listbox
> open event
> me.CellType(0,0) we.TypeCheckBox
> Program runs but it opens the debugger at this line and I don't
> know why.

Try changing it to:

me.CellType(0,0)QstBox.TypeCheckBox.

I think the me.TypeCheckBox is incorrect. What was the error reported?

Terry

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 04:48 (Mon, 08 May 2006 20:48:26 -0700)
From: Terry Ford

On May 8, 2006, at 8:36 PM, Terry Ford wrote:

>
> On May 8, 2006, at 7:48 PM, Barrie Jones wrote:
>
>> How do I get checkboxes in a list box? I tried this in the listbox
>> open event
>> me.CellType(0,0) (e.TypeCheckBox
>> Program runs but it opens the debugger at this line and I don't
>> know why.
>
> Try changing it to:
>
> me.CellType(0,0)astBox.TypeCheckBox.
>
> I think the me.TypeCheckBox is incorrect. What was the error reported?

It also has to exist. Also a number can be used. Here's a simple Open
test for a listbox:

me.AddRow "Blue"
me.CellType(0,0) [or me.CellType(0,0)0stBox.TypeCheckBox]

HTH,

Terry

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 04:50 (Mon, 8 May 2006 23:50:08 -0400)
From: Barrie Jones
Thanks. I tried the suggestion and got the same result. The debugger
does not report an error... just pastes a ladyBird bug at the side of
the code.
I can't find an example in the manual and can't find one in the
examples folder.
Any other suggestions?
Barrie
On May 8, 2006, at 11:36 PM, Terry Ford wrote:

>
> On May 8, 2006, at 7:48 PM, Barrie Jones wrote:
>
>> How do I get checkboxes in a list box? I tried this in the listbox
>> open event
>> me.CellType(0,0) ve.TypeCheckBox
>> Program runs but it opens the debugger at this line and I don't
>> know why.
>
> Try changing it to:
>
> me.CellType(0,0)ystBox.TypeCheckBox.
>
> I think the me.TypeCheckBox is incorrect. What was the error reported?
>
> Terry
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 04:53 (Mon, 08 May 2006 20:53:49 -0700)
From: Terry Ford

On May 8, 2006, at 8:50 PM, Barrie Jones wrote:

> Thanks. I tried the suggestion and got the same result. The
> debugger does not report an error... just pastes a ladyBird bug at
> the side of the code.

Did you check the bottom of the error window?

Terry

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 04:57 (Mon, 8 May 2006 23:57:05 -0400)
From: Barrie Jones
Terry, you are spot on. I had not entered anything in the list box.
Now it is working. Thankyou.
Barrie
On May 8, 2006, at 11:48 PM, Terry Ford wrote:

>
> On May 8, 2006, at 8:36 PM, Terry Ford wrote:
>
>>
>> On May 8, 2006, at 7:48 PM, Barrie Jones wrote:
>>
>>> How do I get checkboxes in a list box? I tried this in the
>>> listbox open event
>>> me.CellType(0,0) .e.TypeCheckBox
>>> Program runs but it opens the debugger at this line and I don't
>>> know why.
>>
>> Try changing it to:
>>
>> me.CellType(0,0)lstBox.TypeCheckBox.
>>
>> I think the me.TypeCheckBox is incorrect. What was the error
>> reported?
>
> It also has to exist. Also a number can be used. Here's a simple
> Open test for a listbox:
>
> me.AddRow "Blue"
> me.CellType(0,0) [or me.CellType(0,0)rstBox.TypeCheckBox]
>
> HTH,
>
> Terry
>
> _______________________________________________
> Unsubscribe or switch delivery mode:
> <http://www.realsoftware.com/support/listmanager/>
> Search the archives of this list here:
> <http://support.realsoftware.com/listarchives/lists.html>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 05:05 (Mon, 08 May 2006 21:05:58 -0700)
From: Terry Ford

On May 8, 2006, at 8:57 PM, Barrie Jones wrote:

> Terry, you are spot on. I had not entered anything in the list box.
> Now it is working. Thankyou.

You can also use me.ColumnType(0) before you addrow(s) if you wish
to set all rows in the column to be a checkbox type.

You probably got an OutOfBounds error for the cell method.

Terry

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 05:15 (Tue, 9 May 2006 00:15:24 -0400)
From: Barrie Jones
Right again. It was an out of bounds exception. I finally found the
error message at the bottom of the window (as you suggested). Thanks
again.
Barrie

On May 9, 2006, at 12:05 AM, Terry Ford wrote:

>
> On May 8, 2006, at 8:57 PM, Barrie Jones wrote:
>
>> Terry, you are spot on. I had not entered anything in the list
>> box. Now it is working. Thankyou.
>
> You can also use me.ColumnType(0) before you addrow(s) if you
> wish to set all rows in the column to be a checkbox type.
>
> You probably got an OutOfBounds error for the cell method.
>
> Terry
>
> _______________________________________________
> Unsubscribe or switch delivery mode:
> <http://www.realsoftware.com/support/listmanager/>
> Search the archives of this list here:
> <http://support.realsoftware.com/listarchives/lists.html>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 15:24 (Tue, 9 May 2006 07:24:55 -0700 (PDT))
From: D Prowse
Hi Terry, Barrie
I've been interested in your listbox question/answer set over the last bit. I've been trying to set up a two column listbox that has checkboxes in col 0 and text in col 1. I've built a crude question set randomizer for a teacher friend of mine and am refining it a little. Initially I just used a letter in cell(i,0) and tracked by array. (By the checkbox I am allowing the user to pick the questions that are to stay 'unrandomized')

In the listbox open I have:

dim i as integer
for i l to 99
me.AddRow ""
me.CellType(i,0)
check(i) oalse
me.cell(i,1) oDummy Text"
next

"Dummy Text" is in place of array elements holding questions that a method elsewhere randomizes.

check() is an array of boolean to track if the cell(i,0) has been checked (true / false).

Obviously filled with initial false. I did this because I can't find how to access the true/false property of the checkbox when in a cell. It would be nice to just check the condition of the checkbox instead of dragging all these arrays around.

thanks
Derek

rb206r2 XP

Barrie Jones <<email address removed>> wrote:
Right again. It was an out of bounds exception. I finally found the
error message at the bottom of the window (as you suggested). Thanks
again.
Barrie

On May 9, 2006, at 12:05 AM, Terry Ford wrote:

>
> On May 8, 2006, at 8:57 PM, Barrie Jones wrote:
>
>> Terry, you are spot on. I had not entered anything in the list
>> box. Now it is working. Thankyou.
>
> You can also use me.ColumnType(0) before you addrow(s) if you
> wish to set all rows in the column to be a checkbox type.
>
> You probably got an OutOfBounds error for the cell method.
>
> Terry
>
> _______________________________________________
> Unsubscribe or switch delivery mode:
>
> Search the archives of this list here:
>

_______________________________________________
Unsubscribe or switch delivery mode:

Search the archives of this list here:



---------------------------------
How low will we go? Check out Yahoo! Messenger’s low PC-to-Phone call rates.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 16:13 (Tue, 9 May 2006 11:13:06 -0400)
From: Charles Yeomans

On May 9, 2006, at 10:24 AM, D Prowse wrote:

> Hi Terry, Barrie
> I've been interested in your listbox question/answer set over the
> last bit. I've been trying to set up a two column listbox that has
> checkboxes in col 0 and text in col 1. I've built a crude question
> set randomizer for a teacher friend of mine and am refining it a
> little. Initially I just used a letter in cell(i,0) and tracked by
> array. (By the checkbox I am allowing the user to pick the
> questions that are to stay 'unrandomized')
>
> In the listbox open I have:
>
> dim i as integer
> for i q to 99
> me.AddRow ""
> me.CellType(i,0) > check(i) _alse
> me.cell(i,1) fDummy Text"
> next
>
> "Dummy Text" is in place of array elements holding questions that
> a method elsewhere randomizes.
>
> check() is an array of boolean to track if the cell(i,0) has been
> checked (true / false).
>
> Obviously filled with initial false. I did this because I can't
> find how to access the true/false property of the checkbox when in
> a cell. It would be nice to just check the condition of the
> checkbox instead of dragging all these arrays around.

See Listbox.CellCheck.

Charles Yeomans
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 16:54 (Tue, 9 May 2006 08:54:32 -0700)
From: CV

On May 9, 2006, at 8:13 AM, Charles Yeomans wrote:

>
> On May 9, 2006, at 10:24 AM, D Prowse wrote:
>
>> Hi Terry, Barrie
>> I've been interested in your listbox question/answer set over
>> the last bit. I've been trying to set up a two column listbox that
>> has checkboxes in col 0 and text in col 1. I've built a crude
>> question set randomizer for a teacher friend of mine and am
>> refining it a little. Initially I just used a letter in cell(i,0)
>> and tracked by array. (By the checkbox I am allowing the user to
>> pick the questions that are to stay 'unrandomized')
>>
>> In the listbox open I have:
>>
>> dim i as integer
>> for i u to 99
>> me.AddRow ""
>> me.CellType(i,0) >> check(i) alse
>> me.cell(i,1) 4Dummy Text"
>> next
>>
>> "Dummy Text" is in place of array elements holding questions
>> that a method elsewhere randomizes.
>>
>> check() is an array of boolean to track if the cell(i,0) has
>> been checked (true / false).
>>
>> Obviously filled with initial false. I did this because I can't
>> find how to access the true/false property of the checkbox when in
>> a cell. It would be nice to just check the condition of the
>> checkbox instead of dragging all these arrays around.
>>
> See Listbox.CellCheck.
>

It's also useful to know that the CellAction event fires whenever a
checkbox is clicked.

Best,

Jack
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Re: Check box in a list box
Date: 09.05.06 17:23 (Tue, 9 May 2006 09:23:39 -0700 (PDT))
From: D Prowse
Thanks to both of you. I was being stupid here. I'm moving from VB to rb and am not always using the LR properly.

I looked under events and didn't see what I needed. Under properties! Duh. CellType works for my simple little app. The CellAction firing is something i might have used if I had started differently.

Sorry for wasting your time. Your discussions are always helpful.
cheers
D

CV <<email address removed>> wrote:

On May 9, 2006, at 8:13 AM, Charles Yeomans wrote:

>
> On May 9, 2006, at 10:24 AM, D Prowse wrote:
>
>> Hi Terry, Barrie
>> I've been interested in your listbox question/answer set over
>> the last bit. I've been trying to set up a two column listbox that
>> has checkboxes in col 0 and text in col 1. I've built a crude
>> question set randomizer for a teacher friend of mine and am
>> refining it a little. Initially I just used a letter in cell(i,0)
>> and tracked by array. (By the checkbox I am allowing the user to
>> pick the questions that are to stay 'unrandomized')
>>
>> In the listbox open I have:
>>
>> dim i as integer
>> for i : to 99
>> me.AddRow ""
>> me.CellType(i,0) >> check(i) alse
>> me.cell(i,1) oDummy Text"
>> next
>>
>> "Dummy Text" is in place of array elements holding questions
>> that a method elsewhere randomizes.
>>
>> check() is an array of boolean to track if the cell(i,0) has
>> been checked (true / false).
>>
>> Obviously filled with initial false. I did this because I can't
>> find how to access the true/false property of the checkbox when in
>> a cell. It would be nice to just check the condition of the
>> checkbox instead of dragging all these arrays around.
>>
> See Listbox.CellCheck.
>

It's also useful to know that the CellAction event fires whenever a
checkbox is clicked.

Best,

Jack
_______________________________________________
Unsubscribe or switch delivery mode:

Search the archives of this list here:



---------------------------------
Yahoo! Messenger with Voice. PC-to-Phone calls for ridiculously low rates.
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>





Links
MBS Realbasic Chart Plugins - Pfarrgemeinde Messdiener Nickenich