Counting Objects on a worksheet ....

chander

New Member
Joined
Dec 2, 2002
Messages
19
i hv got one problem with OLEObjects if any of u guy can help me out ..
I got some Some OLEObjects and/or Embedded objects in my workbook/sheet . I want to know its count and if there is even one object like form control , OLE object , embedded control , class/DLL library etc. i want to take some action.I am checking this by Putting a msgbox in Workbook_Open like

Msgbox Activeworkbook.Worksheets("Sheet1").OLEObjects.Count

and i put a command buttong and List box on Sheet and open workbook ..

The workbook_open event never gets fire when i open the workbook ... Not only Workbook_open event , even no event after tht gets fire... how i can come to know while opening my work book tht it has Form control or any other object in it so that i can take my action ...
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
humm i did but it hink problem was some where else .. my security setting on tht workbook was high and maros were disabled so code was not running ... its working now ...
 
Upvote 0

Forum statistics

Threads
1,221,709
Messages
6,161,432
Members
451,705
Latest member
Priti_190

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top