LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default InputBox value in formula problem

Can anyone tell me what the problem is with the following code?
Period = InputBox("Input invoice period, e.g. AUG-07", "Period")
Sheets("ANNUAL MASTER").Select
Range("D7").Select
ActiveCell.FormulaR1C1 = "=Spreadsheet!R[-5]C[-3] &"" """ & Period

When I run this in a Macro, I get a VB "Run-time error '1004':
Application-defined or object-defined error". It doesn't seem to like the "&
Period" portion at the end of the last line. If I take that piece out, it
works fine. The code seems to conform to the syntax that I have seen in many
other places, so I'm stumped.

Any help would be greatly appreciated!
 
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
Help needed with Inputbox problem Gary''s Student Excel Programming 3 April 10th 07 03:31 PM
Help needed with Inputbox problem Norman Jones Excel Programming 3 April 10th 07 02:43 PM
Inputbox/Regression Problem Matt[_36_] Excel Programming 2 February 20th 06 08:15 PM
Inputbox/Regression Problem MattB[_3_] Excel Programming 0 February 17th 06 06:29 PM
Inputbox for Worksheet name - problem Stuart[_5_] Excel Programming 3 February 13th 04 07:02 PM


All times are GMT +1. The time now is 10:22 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"