Text from Text Boxes in Word into Excel Spreadsheet

G

Guy Billinge

I have created a questionnaire using the Control Toolbox items and I need to
get the information that is entered into them by a user, into an Excel
spreadsheet.
I need to know how to get the information from a Text Box (named tbSurname)
into an Excel spreadsheet.

Any help would be greatly appreciated
 
E

Ed

Untested, but I think it would be something like:
xlApp.xlWB.Worksheets("Sheet1").Range("A1").Text = tbSurname.Text
where xlApp is your object for the Excel application, and
xlWB is your object for the specific workbook. Change "Sheet1" to reflect
the actual name of your worksheet, and "A1" to the actual cell reference.

HTH
Ed
 
G

Guy Billinge

Apologies, i neglected to mention that the questionnaire has been created in
Microsoft Word (significant detail i know!!). So i have a questionnaire in
Word using Control Toolbox items and I need to get the information entered
into these Control Toolbox items into an Excel spreadsheet.

Apologies once again, any help would be greatly appreciated
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top