How to Use Global Form Controls

  • Thread starter Thread starter Kevin
  • Start date Start date
K

Kevin

I have two distinct, but related problems.

1) I have form that has a listbox control. On xx_Load(), I load the
listbox with items from a SQL CE 2005 database table. This table has
several thousand records. It takes 10-15 seconds to load these records.
How can I reduce the amount of time it takes to load the control? Also,
would a datagrid be a better choice?

2) I thought about pre-loading a "global" listbox control with the
values and simply replacing (or adding) the control to the form. How
would I go about setting this up?

Thanks,
Kevin
 
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a good
idea? Much better to *not* fill the control with anything until the user
gives you some guidance on what really needs to be displayed.

Paul T.
 
Thanks for the input, Paul. How can you argue the design is flawed if
you don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?
 
The display and use of *thousands* of lines of information is the flaw. A
user cannot make proper use of a listbox control with that many items in it.
Any time you say that you need to populate a list box with that many items,
I'd say that the design if flawed, regardless of whether the use of such UI
is widespread or not.

Is there no other characteristics that you can use to filter the
information? If there are thousands of items in a 'room', are they all of
the same type? Is there no more-localized information about them (rack # or
something)? Hell, 'color' would be better than nothing!

No, I don't believe that you'll be able to do any better, as long as you
insist on stuffing a control that full of data.

Paul T.

Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if you
don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until the
user gives you some guidance on what really needs to be displayed.

Paul T.
 
I see your point. The list of items is not a list of items that are
contained in the room. This is a list of "standard" items the user must
choose. In other words, the user has chosen (scanned) a room
tag/barcode. Now the application says, "what is the item you are going
to scan?" That's what the user will be selecting. It's not really an
issue of trying to filter the items. Regardless of how the filtering
will take place, time will be needed to select the items. I could show
an empty listbox with an editbox below, and allow the user to start
entering a description. But, the user may not even know what the
description would look like. It could be cryptic or straightforward.

One would think that a datagrid would be capable of handling this size
of data, but it shows that same symptoms: it takes about 10-15 seconds
to populate the list.

I just need to be able to quickly (or reasonably quickly) display the
entire list to the user so s/he can pick the item.
The display and use of *thousands* of lines of information is the flaw. A
user cannot make proper use of a listbox control with that many items in it.
Any time you say that you need to populate a list box with that many items,
I'd say that the design if flawed, regardless of whether the use of such UI
is widespread or not.

Is there no other characteristics that you can use to filter the
information? If there are thousands of items in a 'room', are they all of
the same type? Is there no more-localized information about them (rack # or
something)? Hell, 'color' would be better than nothing!

No, I don't believe that you'll be able to do any better, as long as you
insist on stuffing a control that full of data.

Paul T.

Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if you
don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until the
user gives you some guidance on what really needs to be displayed.

Paul T.

I have two distinct, but related problems.

1) I have form that has a listbox control. On xx_Load(), I load the
listbox with items from a SQL CE 2005 database table. This table has
several thousand records. It takes 10-15 seconds to load these records.
How can I reduce the amount of time it takes to load the control? Also,
would a datagrid be a better choice?

2) I thought about pre-loading a "global" listbox control with the
values and simply replacing (or adding) the control to the form. How
would I go about setting this up?

Thanks,
Kevin
 
It will handle it, but the processor in your Windows CE device isn't your
desktop PC processor. Your expectations are too high for timing of loading
that many items.

Why does the user need to tell the application what he's about to scan? Is
this entering of new assets into the tag database and the list of items is a
list of item types?

You can probably use a single form with the list on it and just show that
each time the user needs to select an item from that list (although I still
would say it's a poor design, although maybe the design of the data is poor,
rather than the application). You'd suffer the delay the first time you
created the form in the application, but not after that (in other words, you
create a form and call ShowDialog on it, but keep the object around and
don't recreate it the next time you need the user to select an item).

Paul T.

Kevin said:
I see your point. The list of items is not a list of items that are
contained in the room. This is a list of "standard" items the user must
choose. In other words, the user has chosen (scanned) a room tag/barcode.
Now the application says, "what is the item you are going to scan?" That's
what the user will be selecting. It's not really an issue of trying to
filter the items. Regardless of how the filtering will take place, time
will be needed to select the items. I could show an empty listbox with an
editbox below, and allow the user to start entering a description. But, the
user may not even know what the description would look like. It could be
cryptic or straightforward.

One would think that a datagrid would be capable of handling this size of
data, but it shows that same symptoms: it takes about 10-15 seconds to
populate the list.

I just need to be able to quickly (or reasonably quickly) display the
entire list to the user so s/he can pick the item.
The display and use of *thousands* of lines of information is the flaw.
A user cannot make proper use of a listbox control with that many items
in it. Any time you say that you need to populate a list box with that
many items, I'd say that the design if flawed, regardless of whether the
use of such UI is widespread or not.

Is there no other characteristics that you can use to filter the
information? If there are thousands of items in a 'room', are they all
of the same type? Is there no more-localized information about them
(rack # or something)? Hell, 'color' would be better than nothing!

No, I don't believe that you'll be able to do any better, as long as you
insist on stuffing a control that full of data.

Paul T.

Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if
you don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?

Paul G. Tobey [eMVP] wrote:
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until
the user gives you some guidance on what really needs to be displayed.

Paul T.

I have two distinct, but related problems.

1) I have form that has a listbox control. On xx_Load(), I load the
listbox with items from a SQL CE 2005 database table. This table has
several thousand records. It takes 10-15 seconds to load these
records. How can I reduce the amount of time it takes to load the
control? Also, would a datagrid be a better choice?

2) I thought about pre-loading a "global" listbox control with the
values and simply replacing (or adding) the control to the form. How
would I go about setting this up?

Thanks,
Kevin
 
Kevin,

I agree with Paul re the design and the number of items in a listbox. Even
if you could load 1000's of items in a listbox quickly the user has no real
control about selecting any of those items.

I'm not sure from how you've described it, but if you are scanning items,
then why can't the items themselves carry a description. If you have the
items in a table each with a barcode, then let the scanner do the work. If
an item can have more than one description, then another related table that
then could display those descriptions of each item in a listbox.

Graham

Kevin said:
I see your point. The list of items is not a list of items that are
contained in the room. This is a list of "standard" items the user must
choose. In other words, the user has chosen (scanned) a room tag/barcode.
Now the application says, "what is the item you are going to scan?" That's
what the user will be selecting. It's not really an issue of trying to
filter the items. Regardless of how the filtering will take place, time
will be needed to select the items. I could show an empty listbox with an
editbox below, and allow the user to start entering a description. But, the
user may not even know what the description would look like. It could be
cryptic or straightforward.

One would think that a datagrid would be capable of handling this size of
data, but it shows that same symptoms: it takes about 10-15 seconds to
populate the list.

I just need to be able to quickly (or reasonably quickly) display the
entire list to the user so s/he can pick the item.
The display and use of *thousands* of lines of information is the flaw.
A user cannot make proper use of a listbox control with that many items
in it. Any time you say that you need to populate a list box with that
many items, I'd say that the design if flawed, regardless of whether the
use of such UI is widespread or not.

Is there no other characteristics that you can use to filter the
information? If there are thousands of items in a 'room', are they all
of the same type? Is there no more-localized information about them
(rack # or something)? Hell, 'color' would be better than nothing!

No, I don't believe that you'll be able to do any better, as long as you
insist on stuffing a control that full of data.

Paul T.

Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if
you don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?

Paul G. Tobey [eMVP] wrote:
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until
the user gives you some guidance on what really needs to be displayed.

Paul T.

I have two distinct, but related problems.

1) I have form that has a listbox control. On xx_Load(), I load the
listbox with items from a SQL CE 2005 database table. This table has
several thousand records. It takes 10-15 seconds to load these
records. How can I reduce the amount of time it takes to load the
control? Also, would a datagrid be a better choice?

2) I thought about pre-loading a "global" listbox control with the
values and simply replacing (or adding) the control to the form. How
would I go about setting this up?

Thanks,
Kevin
 
It's simple to argue. No design that had several thousand items in a list
box is a good one. We need to know nothing else about the application to
know that.

The only way to improve speed is to either trim the list down (which is the
best way) or use something that demand pages in the data.

Other things may affect perf, like database indexing, etc. as well.


--
Chris Tacke - Embedded MVP
OpenNETCF Consulting
Managed Code in the Embedded World
www.opennetcf.com
--




Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if you
don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until the
user gives you some guidance on what really needs to be displayed.

Paul T.
 
The DataGrid only pulls and display the data necessary for the visible
portion of the list, so it's probably not the population of the control
that's your time sink. It's likely the data query. Have you timed it? Is
the table indexed on the field you're selecting from (the fileld in your
WHERE clause)?


--
Chris Tacke - Embedded MVP
OpenNETCF Consulting
Managed Code in the Embedded World
www.opennetcf.com
--



Kevin said:
I see your point. The list of items is not a list of items that are
contained in the room. This is a list of "standard" items the user must
choose. In other words, the user has chosen (scanned) a room tag/barcode.
Now the application says, "what is the item you are going to scan?" That's
what the user will be selecting. It's not really an issue of trying to
filter the items. Regardless of how the filtering will take place, time
will be needed to select the items. I could show an empty listbox with an
editbox below, and allow the user to start entering a description. But, the
user may not even know what the description would look like. It could be
cryptic or straightforward.

One would think that a datagrid would be capable of handling this size of
data, but it shows that same symptoms: it takes about 10-15 seconds to
populate the list.

I just need to be able to quickly (or reasonably quickly) display the
entire list to the user so s/he can pick the item.
The display and use of *thousands* of lines of information is the flaw.
A user cannot make proper use of a listbox control with that many items
in it. Any time you say that you need to populate a list box with that
many items, I'd say that the design if flawed, regardless of whether the
use of such UI is widespread or not.

Is there no other characteristics that you can use to filter the
information? If there are thousands of items in a 'room', are they all
of the same type? Is there no more-localized information about them
(rack # or something)? Hell, 'color' would be better than nothing!

No, I don't believe that you'll be able to do any better, as long as you
insist on stuffing a control that full of data.

Paul T.

Kevin said:
Thanks for the input, Paul. How can you argue the design is flawed if
you don't know the flow of the application? I've seen many commercial
applications that display a huge list of items in a listbox, and the
design of those applications is far from flawed.

Anyway, the application is tracking assets within a particular room:

1) The user enters a room number (6 digits) into an editbox and press
[Next].
2) A list of descriptions for the item is presented. These descriptions
are contained in a table in the database.

We've tried using a datagrid, but it doesn't help with the time issue.

Any suggestions?

Paul G. Tobey [eMVP] wrote:
I'd argue that your UI design is flawed, not the functionality of the
control. A listbox with several *thousand* entries? That seems like a
good idea? Much better to *not* fill the control with anything until
the user gives you some guidance on what really needs to be displayed.

Paul T.

I have two distinct, but related problems.

1) I have form that has a listbox control. On xx_Load(), I load the
listbox with items from a SQL CE 2005 database table. This table has
several thousand records. It takes 10-15 seconds to load these
records. How can I reduce the amount of time it takes to load the
control? Also, would a datagrid be a better choice?

2) I thought about pre-loading a "global" listbox control with the
values and simply replacing (or adding) the control to the form. How
would I go about setting this up?

Thanks,
Kevin
 
Back
Top