Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default File Open Macro

I am trying to write a macro as described below but have run into a wal
based on my visual basic knowledge. Any help would be greatl
appreciated.

Based on what a user selects from various list boxes, I have created
macro to generate a filename. Therefore, certain selections wil
generate the file name "Plant.xls" within cell F1 of my curren
workbook (Summary.xls). Plants.xls is the location of Sheet "1
indicated below. If my filename can change based on user selections
how do I associate a filename with Sheet "1"?

I know how to hardcode my macro so that Sheet "1" is always locate
within "Plant.xls". Unfornately the location of Sheet "1" change
depending on what the user selects. Hopefully this makes sense.


Sheets("1").Select
Application.Run "'Summary.xls'!Formulas"
Application.Run "'Summary.xls'!Copy

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Open Excel file from VB and open MACRO no1jimmyman Excel Discussion (Misc queries) 0 February 14th 11 10:10 PM
2007 Macro to Open File, Delete Contents, Save New File Flintstone[_2_] Excel Discussion (Misc queries) 2 February 1st 10 11:25 PM
Macro to open a file jackrobyn1 Excel Discussion (Misc queries) 4 April 7th 09 12:46 PM
Open File within a macro Rob Excel Discussion (Misc queries) 10 June 29th 06 08:55 PM
Automate open file, update links, run macro, close and save file Geoff[_7_] Excel Programming 2 August 26th 03 10:13 PM


All times are GMT +1. The time now is 06:32 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"