Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Value in a inputbox
Hi!
If i have a value like name in a variable can't i get this value into a inputbox, like "is this name correct?" and if isn't correct i can write a new name in the inputbix? regards alvin |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Value in a inputbox
A message box is probably a better option. The code would be similar to this...
dim intReturnValue as integer intReturnValue = msgbox("Is the name " & myVariable & " Correct?", vbYesNo, "Confirm Name") if intreturnvalue = vbyes then ... else --- endif "Alvin Hansen" wrote: Hi! If i have a value like name in a variable can't i get this value into a inputbox, like "is this name correct?" and if isn't correct i can write a new name in the inputbix? regards alvin |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Value in a inputbox
Sub AAA()
Dim sName As String sName = "Smith" sName = InputBox(Prompt:="Is this Name correct" & _ vbNewLine & "Please correct if wrong", _ Title:="Name Check", _ Default:=sName) MsgBox sName End Sub -- Regards, Tom Ogilvy "Alvin Hansen" wrote in message ... Hi! If i have a value like name in a variable can't i get this value into a inputbox, like "is this name correct?" and if isn't correct i can write a new name in the inputbix? regards alvin |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Value in a inputbox
Thanks again tom its working
regards alvin "Tom Ogilvy" skrev: Sub AAA() Dim sName As String sName = "Smith" sName = InputBox(Prompt:="Is this Name correct" & _ vbNewLine & "Please correct if wrong", _ Title:="Name Check", _ Default:=sName) MsgBox sName End Sub -- Regards, Tom Ogilvy "Alvin Hansen" wrote in message ... Hi! If i have a value like name in a variable can't i get this value into a inputbox, like "is this name correct?" and if isn't correct i can write a new name in the inputbix? regards alvin |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
InputBox | Excel Discussion (Misc queries) | |||
InputBox | Excel Discussion (Misc queries) | |||
inputbox | Excel Discussion (Misc queries) | |||
Inputbox and Application.InputBox | Excel Programming | |||
Inputbox | Excel Programming |