PC Review


Reply
Thread Tools Rate Thread

Changing filename as variable

 
 
New Member
Join Date: Dec 2007
Posts: 2
 
      3rd Dec 2007
I'm not sure if my title is really clear on what I need help with. If not, I apologize.

I have a file that when a user submits it via a selection button, it gets saved with a new name. The issue is that I have some VBA code that needs to use the file name as part of a formula. Maybe this will explain it:
Range("F10").Select 'Project Budget
ActiveCell.FormulaR1C1 = "='[fname]Budget Estimate'!R288C7"
The file name "fname" is equal to "ThisWorkBook.Name" but the above formula gives me a #REF! error in the sheet in another open work book that I'm trying to pass the values to.

Any idea on what I'm doing wrong. Thanks for any help in advance.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Variable Filename Berj Microsoft Excel Programming 1 26th Aug 2008 08:54 AM
filename as variable sck352@gmail.com Microsoft Excel Programming 1 5th Dec 2007 08:47 PM
Filename variable starke1120@hotmail.com Microsoft Excel Programming 17 4th Sep 2006 02:47 PM
Converting a Variable Filename to a Constant Filename =?Utf-8?B?TWFnbml2eQ==?= Microsoft Excel Programming 2 15th Aug 2006 06:13 PM
if i use the filename as variable name DotNetMania Microsoft C# .NET 1 23rd May 2004 10:16 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:28 PM.