Thread: Current File
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Jim Thomlinson[_5_] Jim Thomlinson[_5_] is offline
external usenet poster
 
Posts: 486
Default Current File

A little difficult to comment on without seeing some code. That being said...

Thisworkbook. 'Always refers to the bookk that is executing the code
Activeworkbook. 'refers to whichever book happens to be active at the time

You can also use workbook objects kind of like this

dim wbk as workbook

set wbk = activeworkbook
'Now you can always make reference to the workbook that was acive when this
line of code was run, even if you activate a different workbook...

--
HTH...

Jim Thomlinson


"Jim Berglund" wrote:

I have a pricing spreadsheet which I typically modify and save for each
prospect under the account name. As such, I have t go into the code and
replace all the current filename references.

There must be a better way to do this...

Any ideas, please?

Thanks much,
Jim Berglund