Solved

Excel VBA Prompt to change named range value

Posted on 2015-01-19
2
97 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 49

Accepted Solution

by:
Rgonzo1971 earned 500 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

Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

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

Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
Some code to ensure data integrity when using macros within Excel. Also included code that helps secure your data within an Excel workbook.
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.

823 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