Multiple listbox questions

I have a sales/cost/profitability report that with lots of help from posters 
here I have managed to create a form to filter it by several criteria and its 
all working well, I'm just tweaking it some now and have a few questions:

First I have 2 listboxes 1 for customers (we currently have 346 listed), 1 
for lots (we currently have 663 listed).  On both of them (both multiselect) 
the slider does not work quiet right.  On first load if you drag the slider 
all the way to the bottom, it only goes down about half the list, release the 
mouse button and the slider appears mid way down instead of at bottom where 
you left it, then you can drag it the rest of the way, I assume its because 
we have so many items in both boxes.  Its definitely not a big deal but would 
be handy to resolve this.

Second I have a start date and end date filter by drop down boxes and then 
check boxes for each of our plants to filter by.  I have added after update 
events to update our 2 long listboxes described above with the following code 
in both:

SELECT sales.Customer FROM sales WHERE (((sales!Plant) In 
([plant1]*-1,[plant2]*-2,[plant3]*-3,[plant5]*-5,[plant81]*-81)) And 
((sales![Month End]) Between [StartDate] And [EndDate])) GROUP BY 
sales.Customer ORDER BY sales.Customer; 

After adding the above loading the form slowed considerably, again I realize 
I'm dealing with a lot of info, but am I doing it in an ineffecient way?

Finally I considered having 1 listbox update the options on the other 
listbox but fear that would make things extremely slow, and possibly even 
going both ways, as you update 1 list box the other one updates its available 
options if thats even possible.  Would that be unadvisable?

3/19/2010 4:01:01 PM
access 16762 articles. 3 followers. Follow

0 Replies

Similar Articles

[PageSpeed] 49


Similar Artilces:

Sorting ListBox
Hi I need to control sorting in a CListBox control. I fount that to do this, I have to make it Owner Draw. So I did override the following methods, virtual int CompareItem( LPCOMPAREITEMSTRUCT lpCIS ); virtual void DrawItem(LPDRAWITEMSTRUCT lpDIS); virtual void MeasureItem(LPMEASUREITEMSTRUCT lpMIS); I create it with m_list.Create(LBS_OWNERDRAWFIXED|LBS_SORT|LBS_HASSTRINGS|LBS_NOTIFY|LBS_NOIN TEGRALHEIGHT|WS_HSCROLL|WS_VSCROLL|WS_CHILD|WS_VISIBLE,CRect(0,0,100,100),th is,100); But, in this case the CompareItem doesn't get called. I gets called if I don't use LBS_HASSTRINGS style...

Copy conditional formatting across multiple rows?
I am using Excel 2003 and have created conditional formatting on the first row in the worksheet with a formula as follows =R3C3="No". This works correctly and the formatting of the row works as expected. If I now copy the formatting to the row below, using the 'Fill formatting Only' option when pasting the formatting is still based on the cell referenced in the intial formatting. Is there anyway to reference column 3 more generically in the formatting formula so I do not have to modify the formula on every row? TIA Gil Gil, R3C3 is absolute referencing. You can e...

Excel Send to Question
I have Office XP and I would like to be able to send Excel documents by Outlook Express. But when I go into Internet Properties/Programs, the only email listed is Microsoft Outlook. Does anyone know how to add Outlook Express to the E-Mail Listing? Thanks. Anita Anita It should be listed, that's strange. Try opening Outlook Express and going to Tools - Options. On the General tab there should be a button to make OE the default. Hit that button and see if it does the trick. -- Dick Kusleika MVP - Excel Excel Blog - Daily Dose of Excel "Anita" ...

Header Control Notification question
Hi, I created a class called CMyHeaderCtrl which subclass the CHeaderCtrl class. I wish to handle the HDN_TRACK notification message. So I added the following code: MyHeaderCtrl.h: afx_msg void OnTrack(NMHDR *pNMHDR, LRESULT* pResult); MyHeaderCtrl.cpp: BEGIN_MESSAGE_MAP(CMyHeaderCtrl, CHeaderCtrl) //{{AFX_MSG_MAP(CMyHeaderCtrl) //}}AFX_MSG_MAP ON_NOTIFY_REFLECT(HDN_TRACK,OnTrack) END_MESSAGE_MAP() void CMyHeaderCtrl::OnTrack(NMHDR *pNMHDR, LRESULT* pResult) { AfxMessageBox("Track"); ... } The message is not shown when I try dragging the divider. However, if I change ON_N...

Option Group Question 10-12-07
I have a form with an option group with 5 choices available. The fieldname/control source where this info will be stored is BusUnit: All 1 GC 2 GSP 3 GT 4 SPX 5 As I am sure you already know the value that is saved in my table is the numeric value noted above. That means little to the user. I want the corresponding text value to be saved in my table instead, and I want my default text value to be "All". Note: within my option group, 1 is the default as defined when created using the Wizard. So when a new record is being populated or created the default value is &...

Sum of field value based upon multiple instances of another value
I have a table with the following fields: ITEM TOTAL REF The data is imported from Excel & the value in the ITEM field may be repeated for an instance in the REF field. So for 3 different REF values, the ITEM values may appear up to 3 times. Is it possible to produce a query which will show the total for each ITEM, rather than each instance? Thanks in advance. On Sun, 15 Nov 2009 03:55:01 -0800, NAHolmes <> wrote: >I have a table with the following fields: > >ITEM >TOTAL >REF > >The data is import...

Serialize CString question
Hi, I want to serialize a CString in the document class. It works fine except that there are 2 strange characters at the beginning of the saved file. How can I get rid of it? Here is the code: void CMsgDoc::Serialize(CArchive& ar) { // CString m_sMsgs; if (ar.IsStoring()) { // TODO: add storing code here ar<<m_sMsgs; } else { // TODO: add loading code here ar>>m_sMsgs; } } Thanks in advance. xg Hello! On Wed, 19 Oct 2005 10:39:09 +0800, xg wrote: > Hi, I want to serialize a CString in the document class. It works fine > except that there are ...

Newby Question #3
I am sure that you will tell me that this is not recommended, but I'm going to ask anyway... I have a single domain controller here that is running Win2k with Dual 2.4G processors and a Gig of memory. This server does not do hardly anything all day. It used as a file server only. It is supporting about 60 users. Can I install E2k3 on this server? What are the impacts? If I install a low end server to act as the front end off my DMZ, can I do OWA securely? OWA will only have to support about 5-6 people (which will most likely not all be at the same time). Thanks for any input. Jef...

Beginner Question Re Excel Format
Hello, Using Excel 2007 and XP. New at this. Have Copied to the PC's Clipboard a page of data from a financial program. How do I setup Excel, before doing a Paste of this data, such that Excel "knows" that I want the data to appear in csv format in Excel ? Or, do I (or must I) just Paste it as an Excel Workbook format, and then do a Save-As in the csv format ? Thanks, Bob Have your tried a simple copy & paste? What happens? Do you know about the Data | Text to Columns feature? Can you get the other program to send data to a text file? Sorry to answer a question wi...

CString question
CString ext = path.Right(3); s.Format(_T("length %d\n[FILE %s]\n"), tmpFile.GetLength (), (LPCTSTR)ext); When this line executes I wind up with a string value of "length 1110\n[FILE (null)]\n" If I reverse the parameter usage, I'll get the correct "[FILE GIF]\nlength 1110\n" Does anyone know why I can't use a string for the second optional parameter of Format? Thanks, Scott Since you haven't received any answer yet, I'll throw in my 2 cents. It's not that you cannot use a string for the second parameter (which you by the way don't n...

How can I Insert a Comment into multiple cells in Excel 2003?
I'd like to select various cells in a spreadsheet, then insert a comment which will show up on all of them. It won't let me do it, and this could save me hours of work. Insert the comment into one cell Copy the cell that contains the comment Select all the other cells in which you want the comment Choose Edit>Paste Special Select Comments Click OK Lance wrote: > I'd like to select various cells in a spreadsheet, then insert a comment > which will show up on all of them. It won't let me do it, and this could save > me hours of work. -- Debra Dalgleish Excel ...

Exchange 5.5 to Exchange 2003 migration question
Ok, so I have added my new exchange 2003 server to my organization and moved just about everyone to the new server from our antiquated Exchange 5.5 server. I now want to make the Exchange 2003 server the front end server and relegate the Exchange 5.5 server as a back end one until I am ready to retire it. Is there anything I need to do other than changing where the firewall points from the public IP address in order to accomplish this? I think you are using frontend / backend in the wrong context. Check what these things really do, and then rethink what you are trying to accomplish....

Offline Inventory Question
I have a question about transferring products from offline inventory to main inventory. When a product is selected in offline inventory for transfer back to main inventory, it looks like RMS automatically transfers the entire quantity of that item into main inventory. For example, if we have a quantity of 10 of Item A in offline inventory and we want to transfer Item A to main inventory, RMS forces us to send all 10 back to main inventory. I don't see any way to transfer only some of the offline inventory quantity back to main inventory (for example, to move 5 of Item A from offl...

Multiple Modeless CDialogs that stay inside parent
I would like to create a program where I can have lots of modeless dialog boxes concurrently open inside an application, that stay within the parent just like when using a multiple document interface? Can anyone help or point me to a example? thanks Create your modeless dialog as a WS_CHILD instead of a POPUP. In the dialog editor it is under Style. And make sure the the parent is the main window (Either the frame in an MDI/SDI, or the main dialog in a dialogbased app) AliR "Chris Baker" <> wrote in message news:BBE43D8C-DEA5-4288-...

Macro Question #12
Hello All, Could some please tell me how to write a macro that will past the data from cell 1A into cell C10 if C10 is blank and past the date in C11 if C10 is not blank. Thanks for any help sub XX() if cells(10,3)="" then cells(10,3)=cells(1,1) else cells (11,3)=cells(1,1) end sub >-----Original Message----- >Hello All, > >Could some please tell me how to write a macro that will >past the data from cell 1A into cell C10 if C10 is blank >and past the date in C11 if C10 is not blank. > > >Thanks for any help >. > Thanks for the reply >----...

Multiple Storage Groups and Databases
I would like input regarding the pro's and con's of using multiple storage groups and multiple databases within those storage groups. We currently have (1) exchange server hosting 100+ mailboxes and is currently 50GB's in total. We want to upgrade to a new box and Ex2003. We are ready for the migration, however want some feedback on the storage issue. Here is what we were thinking????? 3 Storage Groups (named by location/function) then database broken down by department within those storage groups any comment would be greatly appreciated. My comment is that if you are goin...

Automatically Resizing Listboxes
I've written an option pricing model that is constantly updating valuations in real-time based on a datafeed. Because of this, I leave the sheet on autorecalc. On a few of the sheets in the workbook, I have listboxes allowing me to select the tenor of the series I'm trying to price. Occasionally excel goes into a 'death spiral' and begins to resize these boxes automatically until they are almost non-existent and then crashes. The problem is not consistent - many times I can close and reopen excel and the problem is solved. I figure there must be a conflict somewhere, but I...

Unusual Y Axis Scale Question
I am trying to create what is referred to in the medical literature as a "reciprocal creatine curve." The data is rather simple -- just serum creatinine values (Y-axis) over time (X-axis), but the Y-axis scale is quite unusual. The scale is not linear and it's not logarithmic. It's a scale in which the values appear to constantly accelerate. Thus, the distance between 1 and 2 is greater than the distance between 2 and 3, the distance between 2 and 3 is greater than the distance between 3 and 4, etc. Toward the very top of the Y-axis the incremental distance between values be...

Mobile User Issue and Questions
We've been using Exchange 2k3 and Windows Mobile 5 devices provided by Verizon to connect our mobile users. We found that the Treo seems to be the most reliable devices but some users complain about the small keyboard. More importantly we have users who travel out side the country and want to be able to retrieve their email and stay in contact with the main office. Q1) What is the best solution for these users when they travel out of the country. I'm not apposed to changing provides if that is necessary. Q2) We've also considered blackberry but want to make sure we can sti...

multiple page sizes
IS it possible to have two different page sizes within the same document. for 1 is 8.5x11, page 2 is 11x17 and page 3 is 8.5x11? I know how to change page size within the document but it changes the page size for EVERY page.... is there a way to limit it to making the change to one page only? Thanks How do you plan to print this document? The only way I can suggest is to setup your publication as 11x17, insert a page. Divide page one into two pages, Arrange, Layout Guides, set your margins, Grid Guides, 2 columns, spacing, 2 times the margin. Adding a center g...

I have a spreadsheet with about 6 columns and 25 rows of data. One of the columns represents dollar amounts...and the remaining columns represent account names, account numbers...etc. I'm trying to come up with a way to sum all the dollar amounts if the data in the other columns is the same. I've used the sumif formula when I have only one piece of data I'm looking for in common, but how can I get the same result when I'm looking for information with at least two columns of the same data? I've tried used the sumproduct formula. =SUMPRODUCT(($B$106:$B$505="*042000...

Multiple Versions of Unsupported
Running Multiple Versions of Internet Explorer On Single Operating System is Unsupported On Thu, 11 Mar 2010 19:57:32 -0500, "PA Bear [MS MVP]" <> wrote: >Running Multiple Versions of Internet Explorer On Single Operating System is >Unsupported > Interesting that you posted this... was this in reference to another thread? I'd actually like to try running IE7 & IE8 on Vista... are there people who have hacked this on and posted a guide? Formal ...

multiple outlook accounts problem with sent messages
I have a POP email account as my main account and I added a second account - an MS Exchange account. I have everything working beautifully but one odd thing. When I create a new email and say to use the Exchange server all works fine except when I send it. It sends fine but I save a copy of the sent message and when it saves it, it goes to the POP Account Sent Items folder. When I delete Email from my Exchange Inbox they go into the Exchange Deleted folder so that works fine. It's just when I send from Exchange it goes to the POP Account Sent Items folder. I do not have any rules set...

Question: Relative CPU Usage of SUMIFS & SUMPRODUCT
I'm building an Excel model that will summarize data from a table (18,000 rows x 65 columns), and I want to minimize the number of calculations / CPU utilization. So my question is: Is it more efficient (CPU utilization) to use SUMIFS or SUMPRODUCT? Thanks, -- Matthew >Is it more efficient (CPU utilization) to use >SUMIFS or SUMPRODUCT? Use SUMIFS -- Biff Microsoft Excel MVP "Matthew" <> wrote in message > I'm building an Excel model that will summarize data fr...

excel advanced question
i have made a dropdown box with diff selections in it. wat i'd like to do is when one of them is selected i'd like the boxes below that to change name accordingly. is this possible? if my question is not detailed enough i can further explain If I understand you correctly; you are looking for dependent dropdow list. Please refer the below link by Debra Dalgleish on the subject "Excel -- Data Validation -- Dependent Dropdowns from a Sorted List " "Excel Data Validation -- Create Dependent Lists" http:/...