View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Andyjk1 Andyjk1 is offline
external usenet poster
 
Posts: 2
Default Changing the activation of a sheet that is unactive and undefined

Hello, I'm actually a new poster. I did some searching on previous
posts and couldn't find an answer to my problem. The broad scope of
what I'm trying to do is in an excel file, to be able to push a button
that will open the open file dialog box and then once that file is
open, copy the information on a tab and paste it onto a tab from the
original file. I've been able to do most of this. I've used the
sendkeys feature to prompt the open file dialog box. However, the
problem that I'm running into is that once the new file opens, I can't
figure out how to make that the active workbook. It keeps on referring
to the original file, which is the active workbook. Part of the reason
this is a problem is because the filename and path can be different
every time this is used, so I can't delcare the specific file name in
the code and activate it from there. It needs to be flexible and
that's why I am accessing the file through the open file dialog box.

Any help would be greatly appreciated.

Thanks,

Andy