Solved

Excel ActiveX combo boxes are slowing file open/save

Posted on 2014-03-19
8
550 Views
Last Modified: 2014-03-19
Greetings,

I am having open/save issues with an Excel XLS formatted workbook.

The workbook starts as 2 worksheets. There no issues at this stage.

The first worksheet contains 2 named ranges, each with 20 items.

The second worksheet contains a lightly formatted form which extends to F23. It also contains 2 columns of 15 (a total of 30 per sheet) ActiveX Combo Boxes which reference the 2 named ranges. The second worksheet is copied within the workbook for each “component” of a particular job. Some jobs require 60 components, thus the second worksheet might be copied (under scripted control) up to 60 times within one workbook. With 60 sheets, the file size remains under 2Mb, containing 1800 (30x60) ActiveX controls.

With that many sheets, the workbook takes 20 seconds or more to load. While that’s not the end of the world, it triggers unpredictable user responses. It just seems wrong on an otherwise fast system.

I first tested by removing all ActiveX Combo Boxes, after which the workbook opened instantaneously. I then substituted all the ActiveX Combo Box controls for Excel Combo Box form controls, after which the workbook also opened instantaneously. Unfortunately the form control version of the combo box does not provide the programmability I require.

Note that anywhere from 1 to 30 of the combo boxes might be selected on any one sheet.

Considering there are only 2 unique combo boxes throughout the entire workbook, how can I make the form more efficient?

Thanks!
0
Comment
Question by:DavidBloom
  • 4
  • 4
8 Comments
 
LVL 46

Expert Comment

by:Martin Liss
ID: 39940411
Can you attach the workbook, or a sample that shows the problem?
0
 
LVL 1

Author Comment

by:DavidBloom
ID: 39940440
Excellent comment. Attached.
ProcessSheets---Template--ver-3g.xls
0
 
LVL 46

Expert Comment

by:Martin Liss
ID: 39940489
Is the following and similar code there because you have a problem with the comboboxes changing size? If so you might try this solution.

I'm of course not familiar with your workbook but if only one combobox needs to be used at any one time then you could also try the floating, single, combobox described in this article of mine.

Private Sub dd10_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
    dd10.Width = 300
End Sub

Open in new window

0
The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

 
LVL 1

Author Comment

by:DavidBloom
ID: 39940606
The VBA is there to temporarily display a 2 column drop down that are wider than the form column. I also tested by keeping the combo boxes and eliminating the VBA, but no difference in load times.

Thank you. I'll read up on your article.
0
 
LVL 1

Author Comment

by:DavidBloom
ID: 39940637
I like it!  Will work on an adaptation of your coding ...

Best to put one floating control per sheet, or one per workbook within a public module (or similar)?
0
 
LVL 46

Accepted Solution

by:
Martin Liss earned 500 total points
ID: 39940948
One per sheet.
0
 
LVL 1

Author Closing Comment

by:DavidBloom
ID: 39940982
Thank you Martin.
0
 
LVL 46

Expert Comment

by:Martin Liss
ID: 39940997
You're welcome and I'm glad I was able to help.

In my profile you'll find links to some articles I've written that may interest you.
Marty - MVP 2009 to 2013
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Workbook link problems after copying tabs to a new workbook? David Miller (dlmille) Intro Have you either copied sheets to a new workbook, and after having saved and opened that workbook, you find that there are links back to the original sou…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question