ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Quarantine Workbooks (https://www.excelbanter.com/excel-discussion-misc-queries/195404-quarantine-workbooks.html)

Chacky

Quarantine Workbooks
 
Tim879

Thanks for the help. This is the sort of thing I am looking for but when I
run the macro I get the message

RUN TIME ERROR '438'
OBJECT DOESN'T SUPPORT THIS PROPERTY OR METHOD

"Tim879" wrote:

I'm not sure of the code to open the workbooks but if you open all of
the workbooks first, then this macro will work.


sub quarantine()

for x =1 to application.workbooks.count
application.workbooks(x).select
sheets(1).select
range(a1).value = "Quarantine"
next
end sub


On Jul 11, 12:10 pm, Chacky wrote:
is it possible to do a global quarantine of a selection of workbooks by
adding the word 'QUARANTINE' to the same cell in each workbook, without
having to open each workbook one at a time. Hopefully I would be able to
specifiy the size and colour of font also.

i.e. selecting a number of workbooks in a folder then running a macro to do
an update to a particular cell. Or is there a system already built into Excel
to allow this? Ihaven't found one.





Ron de Bruin

Quarantine Workbooks
 
hi Chacky

See
http://www.rondebruin.nl/copy4.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Chacky" wrote in message ...
Tim879

Thanks for the help. This is the sort of thing I am looking for but when I
run the macro I get the message

RUN TIME ERROR '438'
OBJECT DOESN'T SUPPORT THIS PROPERTY OR METHOD

"Tim879" wrote:

I'm not sure of the code to open the workbooks but if you open all of
the workbooks first, then this macro will work.


sub quarantine()

for x =1 to application.workbooks.count
application.workbooks(x).select
sheets(1).select
range(a1).value = "Quarantine"
next
end sub


On Jul 11, 12:10 pm, Chacky wrote:
is it possible to do a global quarantine of a selection of workbooks by
adding the word 'QUARANTINE' to the same cell in each workbook, without
having to open each workbook one at a time. Hopefully I would be able to
specifiy the size and colour of font also.

i.e. selecting a number of workbooks in a folder then running a macro to do
an update to a particular cell. Or is there a system already built into Excel
to allow this? Ihaven't found one.






All times are GMT +1. The time now is 07:48 PM.

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