Pop-Up Box

  • Thread starter Thread starter cassy01
  • Start date Start date
C

cassy01

IS IT POSSIBLE TO:

When i click on a button a pop-up box appears where it asks the user to
enter a value then clicks "ok" ?

When clicking ok the value in the box is sent to cell "A64".

Many Thanks
Benn
 
Maybe...

Private sub Commandbutton1_Click()
Sheets("Form").range("a64").value = Textbox1.Text
End Sub

It'll do the work when they hit that Commandbutton1 (ok???) button.
 
Cassy01,

I'm confused on what you are trying to say. I assumed that you already
have a command button that prompts a userform. If not create one. Click
on design mode, click on the commandbutton then right click, pick view
code and place this code into the sheet. This will make the userform
appear.


Code:
--------------------

Private Sub Commandbutton1
Application.Visible = False
UserForm1.show
Application.Visible = True

--------------------


Make sure you have already created the userform before tyring this
code.

The codes given earlier need to be placed into the userform with the
textbox and commandbutton that you are intending to use.




Code:
--------------------

Private sub Commandbutton1_Click()
Sheets("Sheet1").Activate
Cells(64, 1) = Textbox1.Text
End Sub

Private Sub Textbox1_Change()
End Sub
--------------------


This was based on your first question below:

"When i click on a button a pop-up box appears where it asks the user
to enter a value then clicks "ok" ?"

When clicking ok the value in the box is sent to cell "A64".
 
Back
Top