|
-
Apr 29th, 2005, 12:12 PM
#1
Thread Starter
New Member
Input Box for an excel macro?
Alright, I have an extra credit project due at 2:30pm, and I am stuck on it.
www.cse.psu.edu/~hansford/extraCreditProject.htm
I have this code so far, i just can't finish it
Sub InvestmentCalc()
'
' InvestmentCalc Macro
' Macro recorded 4/13/2005 by jdh336
'
'
Dim rng
strRng = InputBox("Enter Last Cell To Be Filled")
Range("G3:G10").Select
ActiveCell.FormulaR1C1 = "=RC[-2]*RC[-1]"
Range("G3:g10").Select
Selection.AutoFill Destination:=Range("G3:G6"), Type:=xlFillDefault
Range("G3:strRng").Select
End Sub
I am getting a 1004 error telling me that "autofill method of range class failed"
Can anyone help me?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|