PDA

View Full Version : Solved: Displaying cell data in inputbox text



Jow
04-09-2008, 05:47 AM
I'm calling up an inputbox to enter custom data into a cell if a "\" is found somewhere within that cell.
What I want to do is display the current cell contents within the text on the inputbox window...So it would read "Provider Name not recognised, please type in manually...(cell value here)..."

Can that be done?



If .Value Like "*\*" Then
UserEntry = InputBox("Provider Name not recognised, please type in manually...")
If UserEntry <> "" Then Range("D1").Value = UserEntry
End If
End If

rory
04-09-2008, 06:11 AM
Do you mean:
UserEntry = InputBox("Provider Name not recognised, please type in manually..." & .Value)
or:

UserEntry = InputBox("Provider Name not recognised, please type in manually...",, .Value)

Jow
04-10-2008, 08:41 AM
Thanks, you helped me figure it out!

Code I used -


If .Value Like "*\*" Then
UserEntry = InputBox("Provider Name not recognised, please type in manually..." & vbNewLine & Range("D1"))


If UserEntry <> "" Then Range("D1").Value = UserEntry
End If
End If