Discussion:
Listbox, odd behavior
TJ Hanson
2016-11-03 20:16:46 UTC
Permalink
I have a listbox that was working, but now exhibits some odd behavior. When I click on row 0 nothing happens; but when I click on row 1 it gets selected and says that I selected row 0. The listbox doing this has a heading. When I select row 4 it says I selected row 3. So it is always 1 off. It's as if row 0 is acting like a heading, even though I already have a heading.

Also, when I load the listbox not all rows are displayed. After many hours I discovered that if I refresh the window the listbox rows will display correctly. I have never had this situation with any listbox, and I use listboxes all the time.

The listbox is on a page panel. Could this be related? Or might this be a memory problem? I have not received any low memory errors. I did not find anything about this in the NUG archives. I also went back to a XOJO version of 2015, compiled the app and the problem was still there.

Any ideas will be greatly appreciated, Thank you. TJ


_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
vaughnsc .
2016-11-03 20:29:48 UTC
Permalink
I remember having both issues (5 years ago?) I recall it having something
happening in the background with the control focus shifting. May also
affected Listbox.RowFromXY(?) values which was my fallback attempt.

To be honest, I don’t think I ever found the why (Feedback was shot down) I
just worked around it or scaled back what I was trying to do. Frustrating.

Just want you to know you're not the only one that's seen this.

Vaughn
On Nov 3, 2016 4:17 PM, "TJ Hanson" <***@forestmgt.com> wrote:

I have a listbox that was working, but now exhibits some odd behavior. When
I click on row 0 nothing happens; but when I click on row 1 it gets
selected and says that I selected row 0. The listbox doing this has a
heading. When I select row 4 it says I selected row 3. So it is always 1
off. It's as if row 0 is acting like a heading, even though I already have
a heading.

Also, when I load the listbox not all rows are displayed. After many hours
I discovered that if I refresh the window the listbox rows will display
correctly. I have never had this situation with any listbox, and I use
listboxes all the time.

The listbox is on a page panel. Could this be related? Or might this be a
memory problem? I have not received any low memory errors. I did not find
anything about this in the NUG archives. I also went back to a XOJO version
of 2015, compiled the app and the problem was still there.

Any ideas will be greatly appreciated, Thank you. TJ


_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
_______________________________________________
Unsubscribe by sending a message to:
<nug-leave@
TJ Hanson
2016-11-03 20:53:47 UTC
Permalink
Frustrating is a good description. I’m doing in-cell editing so a workaround would be difficult. TJ
Post by vaughnsc .
I remember having both issues (5 years ago?) I recall it having something
happening in the background with the control focus shifting. May also
affected Listbox.RowFromXY(?) values which was my fallback attempt.
To be honest, I don’t think I ever found the why (Feedback was shot down) I
just worked around it or scaled back what I was trying to do. Frustrating.
Just want you to know you're not the only one that's seen this.
Vaughn
I have a listbox that was working, but now exhibits some odd behavior. When
I click on row 0 nothing happens; but when I click on row 1 it gets
selected and says that I selected row 0. The listbox doing this has a
heading. When I select row 4 it says I selected row 3. So it is always 1
off. It's as if row 0 is acting like a heading, even though I already have
a heading.
Also, when I load the listbox not all rows are displayed. After many hours
I discovered that if I refresh the window the listbox rows will display
correctly. I have never had this situation with any listbox, and I use
listboxes all the time.
The listbox is on a page panel. Could this be related? Or might this be a
memory problem? I have not received any low memory errors. I did not find
anything about this in the NUG archives. I also went back to a XOJO version
of 2015, compiled the app and the problem was still there.
Any ideas will be greatly appreciated, Thank you. TJ
_______________________________________________
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.c
Gerd Wilmer
2016-11-04 05:35:42 UTC
Permalink
I have experienced this as well, but it is intermittend.
Some listboxes work just fine, others don't

My workaround:
Create a Property: SelectedRow as integer

Listbox1.cellclick populates the SelectedRow

Gerd
Post by TJ Hanson
I have a listbox that was working, but now exhibits some odd behavior. When I click on row 0 nothing happens; but when I click on row 1 it gets selected and says that I selected row 0. The listbox doing this has a heading. When I select row 4 it says I selected row 3. So it is always 1 off. It's as if row 0 is acting like a heading, even though I already have a heading.
Also, when I load the listbox not all rows are displayed. After many hours I discovered that if I refresh the window the listbox rows will display correctly. I have never had this situation with any listbox, and I use listboxes all the time.
The listbox is on a page panel. Could this be related? Or might this be a memory problem? I have not received any low memory errors. I did not find anything about this in the NUG archives. I also went back to a XOJO version of 2015, compiled the app and the problem was still there.
Any ideas will be greatly appreciated, Thank you. TJ
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.com>
emile.a.schwarz
2016-11-04 06:21:33 UTC
Permalink
Hi TJ,

 

I never had that one,but I know how odd Xojo can be (is ?).

 

First of all, you have to never run any other application at the same time as you're running Xojo,

Before firing the IDE, clear its cache contents user:Library/Preferences Xojo)

If this continue, and if you can do it, save your project as xml,

Quit,clears the cache.

Power Off, wait one minute.

 

Power On, load the IDE, load the xml (remember no other application at the same time.

Run.

 

If the trouble goes on, add a new user,

Run the IDE, load the xml.

 

If nothing works,

remove the IDE (the whole folder)

you can try to download a fresh version of the IDE and install it,

then lod it, load the xml.

 

At last, try with a different hardware, and move there only your project (download the IDE in the new hardware).

 

 

Beside all of those, I do not know.

 

Emile

 

PS: running OS ? Version ?

Last Xojo I suppose (2016r3).

 
Message du 03/11/16 21:18
De : "TJ Hanson"
A : "XOJO, Inc."
Objet : Listbox, odd behavior
I have a listbox that was working, but now exhibits some odd behavior. When I click on row 0 nothing happens; but when I click on row 1 it gets selected and says that I selected row 0. The listbox doing this has a heading. When I select row 4 it says I selected row 3. So it is always 1 off. It's as if row 0 is acting like a heading, even though I already have a heading.
Also, when I load the listbox not all rows are displayed. After many hours I discovered that if I refresh the window the listbox rows will display correctly. I have never had this situation with any listbox, and I use listboxes all the time.
The listbox is on a page panel. Could this be related? Or might this be a memory problem? I have not received any low memory errors. I did not find anything about this in the NUG archives. I also went back to a XOJO version of 2015, compiled the app and the problem was still there.
Any ideas will be greatly appreciated, Thank you. TJ
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo.
emile.a.schwarz
2016-11-04 06:24:09 UTC
Permalink
Stupid question:

 

did you try your inline editing code in a different (brand new) project ?

 

Iwas in trouble even if I was able to edit the Cell, it tooks time to activate the editing, sometimes it does not worked, etc. When I changed my inline editing code, everything goes correct.

 

Emile

 

 
Message du 03/11/16 21:18
De : "TJ Hanson"
A : "XOJO, Inc."
Objet : Listbox, odd behavior
I have a listbox that was working, but now exhibits some odd behavior. When I click on row 0 nothing happens; but when I click on row 1 it gets selected and says that I selected row 0. The listbox doing this has a heading. When I select row 4 it says I selected row 3. So it is always 1 off. It's as if row 0 is acting like a heading, even though I already have a heading.
Also, when I load the listbox not all rows are displayed. After many hours I discovered that if I refresh the window the listbox rows will display correctly. I have never had this situation with any listbox, and I use listboxes all the time.
The listbox is on a page panel. Could this be related? Or might this be a memory problem? I have not received any low memory errors. I did not find anything about this in the NUG archives. I also went back to a XOJO version of 2015, compiled the app and the problem was still there.
Any ideas will be greatly appreciated, Thank you. TJ
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <***@xojo
TJ Hanson
2016-11-04 16:11:51 UTC
Permalink
I got things working, but not without effort.
1. I did the inline editing on another page panel and it worked.
2. I did the inline editing in another app and it worked.
3. Deleted the listbox control and replaced it with a fresh listbox control and problem persisted.
4. Deleted a section of my app which reduced the apps size by about 40% and problem persisted.
5. Varied the input data and problem persisted.
6. I was convinced it was not a memory issue since the problem was consistent. With memory issues things really get bizarre.
7. I deleted the Xojo cache and problem persisted.
8. I quit all other apps on my machine so Xojo was the only thing running, and problem persisted.
9. I built a load module, quit xojo, launched the app and the problem persisted.
— and I probably did some other stuff that I cannot now remember —

The listbox was inside a groupbox on a page panel. There were quite a few controls in the groupbox (labels, text edits, text areas, radio buttons, etc.). So I pulled the listbox out of that groupbox and it started working correctly. Maybe there is a limit as to how much a groupbox can handle, but I would not think so. The page panel now looks a little odd with the listbox on the outside of the groupbox, but I don’t see that I have any choice. I could rebuild the entire page with all fresh controls, including the groupbox, but there is no guarantee that would work.

I have other groupboxes with just as many controls and they work fine.

Anyway, for those of you that have experienced this problem, maybe a groupbox is the cause.

Thanks for all the responses,

TJ






_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List Help: <listhe
Tim Jones
2016-11-04 19:08:37 UTC
Permalink
Are you checking for the selected row in the CellClick or the Change event?
Post by TJ Hanson
I got things working, but not without effort.
1. I did the inline editing on another page panel and it worked.
2. I did the inline editing in another app and it worked.
3. Deleted the listbox control and replaced it with a fresh listbox control and problem persisted.
4. Deleted a section of my app which reduced the apps size by about 40% and problem persisted.
5. Varied the input data and problem persisted.
6. I was convinced it was not a memory issue since the problem was consistent. With memory issues things really get bizarre.
7. I deleted the Xojo cache and problem persisted.
8. I quit all other apps on my machine so Xojo was the only thing running, and problem persisted.
9. I built a load module, quit xojo, launched the app and the problem persisted.
— and I probably did some other stuff that I cannot now remember —
The listbox was inside a groupbox on a page panel. There were quite a few controls in the groupbox (labels, text edits, text areas, radio buttons, etc.). So I pulled the listbox out of that groupbox and it started working correctly. Maybe there is a limit as to how much a groupbox can handle, but I would not think so. The page panel now looks a little odd with the listbox on the outside of the groupbox, but I don’t see that I have any choice. I could rebuild the entire page with all fresh controls, including the groupbox, but there is no guarantee that would work.
I have other groupboxes with just as many controls and they work fine.
Anyway, for those of you that have experienced this problem, maybe a groupbox is the cause.
Thanks for all the responses,
TJ
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-***@lists.xojo.com>

List H
TJ Hanson
2016-11-04 20:01:12 UTC
Permalink
Yes, and it is finally getting it correct.
Post by Tim Jones
Are you checking for the selected row in the CellClick or the Change event?
Post by TJ Hanson
I got things working, but not without effort.
1. I did the inline editing on another page panel and it worked.
2. I did the inline editing in another app and it worked.
3. Deleted the listbox control and replaced it with a fresh listbox control and problem persisted.
4. Deleted a section of my app which reduced the apps size by about 40% and problem persisted.
5. Varied the input data and problem persisted.
6. I was convinced it was not a memory issue since the problem was consistent. With memory issues things really get bizarre.
7. I deleted the Xojo cache and problem persisted.
8. I quit all other apps on my machine so Xojo was the only thing running, and problem persisted.
9. I built a load module, quit xojo, launched the app and the problem persisted.
— and I probably did some other stuff that I cannot now remember —
The listbox was inside a groupbox on a page panel. There were quite a few controls in the groupbox (labels, text edits, text areas, radio buttons, etc.). So I pulled the listbox out of that groupbox and it started working correctly. Maybe there is a limit as to how much a groupbox can handle, but I would not think so. The page panel now looks a little odd with the listbox on the outside of the groupbox, but I don’t see that I have any choice. I could rebuild the entire page with all fresh controls, including the groupbox, but there is no guarantee that would work.
I have other groupboxes with just as many controls and they work fine.
Anyway, for those of you that have experienced this problem, maybe a groupbox is the cause.
Thanks for all the responses,
TJ
_______________________________________________
_______________________________________________
_______________________________________________
Unsubscribe by sending a message to:
<nug-l

Continue reading on narkive:
Loading...