ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Combo Boxes linked to Cells will not clear. (https://www.excelbanter.com/excel-programming/390381-combo-boxes-linked-cells-will-not-clear.html)

ClintG

Combo Boxes linked to Cells will not clear.
 
Hi, I've inherited a workbook which performs multiple functions and has input
cells and combo boxes on the first sheet (the first sheet serves as an input
page). Information is entered on this input form into cells and combo boxes,
then a button is clicked to enter the info and the macro also clears out the
input cells / boxes. This used to work fine, but something has evidently
happened and now only the cells clear out. The combo boxes stay populated.
I don't see anything in the code that has changed. Any ideas or suggestions?
Thanks!!

Norman Jones

Combo Boxes linked to Cells will not clear.
 
Hi Clint,

Perhaps you could post the relavant button code.



---
Regards,
Norman



"ClintG" wrote in message
...
Hi, I've inherited a workbook which performs multiple functions and has
input
cells and combo boxes on the first sheet (the first sheet serves as an
input
page). Information is entered on this input form into cells and combo
boxes,
then a button is clicked to enter the info and the macro also clears out
the
input cells / boxes. This used to work fine, but something has evidently
happened and now only the cells clear out. The combo boxes stay
populated.
I don't see anything in the code that has changed. Any ideas or
suggestions?
Thanks!!




Kiba

Combo Boxes linked to Cells will not clear.
 
Can you post your code?

"ClintG" wrote:

Hi, I've inherited a workbook which performs multiple functions and has input
cells and combo boxes on the first sheet (the first sheet serves as an input
page). Information is entered on this input form into cells and combo boxes,
then a button is clicked to enter the info and the macro also clears out the
input cells / boxes. This used to work fine, but something has evidently
happened and now only the cells clear out. The combo boxes stay populated.
I don't see anything in the code that has changed. Any ideas or suggestions?
Thanks!!


ClintG

Combo Boxes linked to Cells will not clear.
 
Oops..sorry. Below is the code, it's pretty basic. "Interface" is the first
sheet which serves as an input form. Cell E4 is linked to ComboBox3, Cell E5
is simply an input cell, and Cell E8 is linked to ComboBox5. The ComboBoxes
are placed directly over the corresponding cells, and the code is all written
using references to the cells. When you populate the combo boxes, the cells
do update (I moved one over to make sure). Everything in the workbook
functions (populating the other sheets, calculations, etc...) What is wrong
is the code clears out the cell behind the combo box, but does not update the
combo box. Is there a setting under "properties" that would fix this? Any
ideas would be great!! Thanks!!

Worksheets("INTERFACE").Cells(4, 5).ClearContents
Worksheets("INTERFACE").Cells(5, 5).ClearContents
Worksheets("INTERFACE").Cells(8, 5).ClearContents

"Norman Jones" wrote:

Hi Clint,

Perhaps you could post the relavant button code.



---
Regards,
Norman



"ClintG" wrote in message
...
Hi, I've inherited a workbook which performs multiple functions and has
input
cells and combo boxes on the first sheet (the first sheet serves as an
input
page). Information is entered on this input form into cells and combo
boxes,
then a button is clicked to enter the info and the macro also clears out
the
input cells / boxes. This used to work fine, but something has evidently
happened and now only the cells clear out. The combo boxes stay
populated.
I don't see anything in the code that has changed. Any ideas or
suggestions?
Thanks!!





ClintG

Combo Boxes linked to Cells will not clear.
 
Oops..sorry. Below is the code, it's pretty basic. "Interface" is the first
sheet which serves as an input form. Cell E4 is linked to ComboBox3, Cell E5
is simply an input cell, and Cell E8 is linked to ComboBox5. The ComboBoxes
are placed directly over the corresponding cells, and the code is all written
using references to the cells. When you populate the combo boxes, the cells
do update (I moved one over to make sure). Everything in the workbook
functions (populating the other sheets, calculations, etc...) What is wrong
is the code clears out the cell behind the combo box, but does not update the
combo box. Is there a setting under "properties" that would fix this? Any
ideas would be great!! Thanks!!

"Kiba" wrote:

Can you post your code?

"ClintG" wrote:

Hi, I've inherited a workbook which performs multiple functions and has input
cells and combo boxes on the first sheet (the first sheet serves as an input
page). Information is entered on this input form into cells and combo boxes,
then a button is clicked to enter the info and the macro also clears out the
input cells / boxes. This used to work fine, but something has evidently
happened and now only the cells clear out. The combo boxes stay populated.
I don't see anything in the code that has changed. Any ideas or suggestions?
Thanks!!


Norman Jones

Combo Boxes linked to Cells will not clear.
 
Hi Clint,

Your code works for me, although it may be simplified:

'=============
Public Sub Tester()
Worksheets("INTERFACE").Range("E4:E5,E8").ClearCon tents
End Sub
'<<=============

Are you sure that there is no code behind the ComboBoxes
in the sheet Interface's module?


---
Regards,
Norman


"ClintG" wrote in message
...
Oops..sorry. Below is the code, it's pretty basic. "Interface" is the
first
sheet which serves as an input form. Cell E4 is linked to ComboBox3, Cell
E5
is simply an input cell, and Cell E8 is linked to ComboBox5. The
ComboBoxes
are placed directly over the corresponding cells, and the code is all
written
using references to the cells. When you populate the combo boxes, the
cells
do update (I moved one over to make sure). Everything in the workbook
functions (populating the other sheets, calculations, etc...) What is
wrong
is the code clears out the cell behind the combo box, but does not update
the
combo box. Is there a setting under "properties" that would fix this?
Any
ideas would be great!! Thanks!!

Worksheets("INTERFACE").Cells(4, 5).ClearContents
Worksheets("INTERFACE").Cells(5, 5).ClearContents
Worksheets("INTERFACE").Cells(8, 5).ClearContents

"Norman Jones" wrote:

Hi Clint,

Perhaps you could post the relavant button code.



---
Regards,
Norman



"ClintG" wrote in message
...
Hi, I've inherited a workbook which performs multiple functions and has
input
cells and combo boxes on the first sheet (the first sheet serves as an
input
page). Information is entered on this input form into cells and combo
boxes,
then a button is clicked to enter the info and the macro also clears
out
the
input cells / boxes. This used to work fine, but something has
evidently
happened and now only the cells clear out. The combo boxes stay
populated.
I don't see anything in the code that has changed. Any ideas or
suggestions?
Thanks!!







ClintG

Combo Boxes linked to Cells will not clear.
 
Thanks for taking a look Norman. The problem was - under Tools, Options,
Calculation, it was set on Manual, not Automatic. I figured out that if I
saved the worksheet after making an entry, the combo boxes cleared out. Once
I changed this to Automatic, it cleared out after each entry automatically.
Now I know for next time! Thanks again for your help.

"Norman Jones" wrote:

Hi Clint,

Your code works for me, although it may be simplified:

'=============
Public Sub Tester()
Worksheets("INTERFACE").Range("E4:E5,E8").ClearCon tents
End Sub
'<<=============

Are you sure that there is no code behind the ComboBoxes
in the sheet Interface's module?


---
Regards,
Norman


"ClintG" wrote in message
...
Oops..sorry. Below is the code, it's pretty basic. "Interface" is the
first
sheet which serves as an input form. Cell E4 is linked to ComboBox3, Cell
E5
is simply an input cell, and Cell E8 is linked to ComboBox5. The
ComboBoxes
are placed directly over the corresponding cells, and the code is all
written
using references to the cells. When you populate the combo boxes, the
cells
do update (I moved one over to make sure). Everything in the workbook
functions (populating the other sheets, calculations, etc...) What is
wrong
is the code clears out the cell behind the combo box, but does not update
the
combo box. Is there a setting under "properties" that would fix this?
Any
ideas would be great!! Thanks!!

Worksheets("INTERFACE").Cells(4, 5).ClearContents
Worksheets("INTERFACE").Cells(5, 5).ClearContents
Worksheets("INTERFACE").Cells(8, 5).ClearContents

"Norman Jones" wrote:

Hi Clint,

Perhaps you could post the relavant button code.



---
Regards,
Norman



"ClintG" wrote in message
...
Hi, I've inherited a workbook which performs multiple functions and has
input
cells and combo boxes on the first sheet (the first sheet serves as an
input
page). Information is entered on this input form into cells and combo
boxes,
then a button is clicked to enter the info and the macro also clears
out
the
input cells / boxes. This used to work fine, but something has
evidently
happened and now only the cells clear out. The combo boxes stay
populated.
I don't see anything in the code that has changed. Any ideas or
suggestions?
Thanks!!








All times are GMT +1. The time now is 03:19 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com