input boxes in Excel VBA to ask a user to enter details and save in every cell

VBABEGINER

Well-known Member
Joined
Jun 15, 2011
Messages
1,232
Hello All,

I want vba code. Ask question using Input box and the type answer should place into cell starting from cell a2, b2 and so on..

input box Q.1. Enter ur first name? … answer of this should go in a2.
input box Q.2. Enter ur last name? … answer of this should go in b2.
input box Q.3. Enter ur age? … answer of this should go in c2.
.
.
.
input box Q.10. Enter ur current city name? … answer of this should go in j2.


If suppose user clicked on cancel button on any question of input box, he/she should prompted the same question again until the value not entered.

Pls advise vba code..
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
A better option would be to use a UserForm, you could add the necessary TextBoxes and until you press a button, the data would go to the sheet:

1588898429098.png
 
Upvote 0

Forum statistics

Threads
1,215,066
Messages
6,122,948
Members
449,095
Latest member
nmaske

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top