Unvisible checkbox

M

Madiya

I am adding few checkboxes directly to the worksheet cell by toolbar
(control toolbox).
I have set the enable and visible property to true but still the
checkboxes are not visible.
I intend to assign a macro to each checkbox to carry out some
operations.

I have done it earlier but now cant figure out how to make it visible
permanantly.

Pl help.
Regards,
Madiya
 
N

Norman Jones

Hi Madiya,

The default values for the checkbox's Visible and Enabled properties is
true.

However, the following works for me:

'=============>>
Public Sub Tester()
Dim SH As Worksheet

Set SH = ThisWorkbook.Sheets("Sheet1") '<<=== CHANGE

With SH.OLEObjects("Checkbox1")
.Visible = True
.Enabled = True
End With

End Sub
'<<=============

Post your problematic code.
 
M

Madiya

Hi Norman,
I have run your code but still checkboxes are not visible.

So far I have not written any code. I belive writing a simple code will
not be a problem once I make the checkbox visible. Code is a macro
derived from a macro recorder. It works fine if I run frirectly from
run Macro.

My only problem is checkboxes are not visible.
Regards,
Madiya
 
N

Norman Jones

Hi Madiya,

(1) Are you sure that the checkboxes are on sheet1?
(2) Are you sure that you are using the correct Checkbox name?
(3) How did you hide them?
 
N

NickHK

Madiya,
When you place new control on a worksheet, Excel changes to Design mode.
In design mode, all controls are visible, even if their .Visible has been
set to False
So if you add any control to the worksheet, all controls will become
visible.
If you still do not see your checkboxes, then there are no check boxes on
that sheet.
May be you added them to another sheet, or placed them a long way from A1.

NickHK
 
M

Madiya

Hi Norman,
Checkbox are on sheet1, name is default name (checkbox1).
I have nover tried to hide it. Whenever I add any checkbox on sheet1(
or any other sheet for that matter, it hides itself.

Hi NickHK,
I open a new workbook and on sheet1, I added a checkbox.
When I exited design mode box is not visible. I entered in design mode,
box is not visible. Since I know the location, I moved my mouse on the
same and when mouse chenged, I clicked, box is there and shows only
four corners.

Its so strange!!!

Regards,
Madiya.
 
N

Norman Jones

Hi Madiya,

I would try closing Excel, rebooting your PC and then deleting the contents
of your
Temp directory.

To easily open the Temp folder, try:

Windows | Start | Run | %temp%

Now re-open your file.

If you still experience problems, I would suspect possible corruption. In
this case, try opening a new, virgin file and insert a checkbox. If the new
checkbox is visible, I would try rebuilding your file.
 
M

Madiya

Hi Norman,
I have tried to insert the chkbox in a new vergine file after deleting
entire contents of the temp folder but still it is invisible.
Do you have any other suggessions please?

Regards,
Madiya
 
N

NickHK

What about other controls ?
Or are you saying that all you controls become invisible on a worksheet in
Excel ?

Does the same thing happen to controls in Word ?

NickHK
 
M

Madiya

All the controls in excel sheets(even fresh new virgin workbook/sheets)
behave the same way. However, I discovered that if I go to properties,
these controls are listed there.
On selecting the control, I can mearly see the four corners of the
control (just like nudge points in word, if you know what I mean)

In case of WORD, I am getting the error that "Error! Not a valid
embedded object."

Thanks again to stay with me. I really appriciate it.

Regards,
Madiya.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top