Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Excel VBA Prompt to change named range value

Posted on 2015-01-19
2
Medium Priority
?
126 Views
Last Modified: 2015-01-19
Hello,

i need help with a VBA code that when my i run it, it prompts inputbox to ask me for a value and once i type value in inputbox that becomes the value for my named range "PercTT"

thanks.
0
Comment
Question by:Flora
2 Comments
 
LVL 54

Accepted Solution

by:
Rgonzo1971 earned 2000 total points
ID: 40557374
Hi,

pls try

Sub Macro2()
    Res = InputBox("enter the PercTT value")
    ActiveWorkbook.Names("percTT").Value = "=" & Res
End Sub

Open in new window

Regards
0
 
LVL 6

Author Closing Comment

by:Flora
ID: 40557387
thanks.

worked perfectly.

my question which is somehow related to this, is pending, appreciate if you could look into this too

http://www.experts-exchange.com/Software/Office_Productivity/Office_Suites/MS_Office/Excel/Q_28599236.html
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a serious pitfall that can happen when deleting shapes using VBA.
After seeing numerous questions for Dynamic Data Validation I notice that most have used Visual Basic to solve the problem. This suggestion is purely formula based and can be used in multiple rows.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question