View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
NickHK NickHK is offline
external usenet poster
 
Posts: 4,391
Default vba to set calendar object auto load to TRUE

Michael,
Reading the help on the property :
"This property is ignored by ActiveX controls. ActiveX controls are always
loaded when a workbook is opened."
and
"For most OLE object types, this property shouldn't be set to True"

I've always been somewhat unsure of the difference between MSs definitions
of OLE and ActiveX in a VB/VBA sense, so, I'm not sure if the above applies,
although to me the calendar control is an ActiveX control that becomes an
OLE object once on the WS.

However, AutoLoad is member of OLEObjects, not Shapes.

Not really an answer, but...

NickHK

"michael.beckinsale" wrote in message
ups.com...
Hi All,

I have a calendar control object on my worksheet that is named
'calendar1' When i go into design mode it says that the embedded
control is 'MSCAL.Calendar.7'

I would like to set the 'autoload' property to TRUE on opening the
workbook but cant seem to get the coding right. Here's what l have
tried:

ActiveSheet.Shapes("Calendar1").AutoLoad = True

Can anybody help with this code please?

Regards

Michael Beckinsale