Forum Discussion

TIndermuehle's avatar
TIndermuehle
Copper Contributor
Nov 10, 2024

VBA code for Excel form that populates a table

Hello

I'm using Office 365 for Windows on a federals government computer system. I track the food and beverage inventory that is stocked from 11 floors and units in a hospital.  I had to consolidate it onto one table and complicated me entering data easily.
I created a form using Excel VBA to in put data onto a spreadsheet labeled Floor stock data.  There are no values assigned to the entry cells.

 

The spreadsheet column names are exactly the same and in the same order as the input form I created. The columns range from A to BR.


I need the form to move to the next input box after I hit the enter button on my keyboard.

When I push the ENTER button on the form I need to transfer the data to an open row below the previous data. In this case its row 604. I then need to reset the form and clear the data.

I need to write the next record on the next row after that.

The form needs to reset and the values need to clear after I use the form ENTER button.


I've looked online but the videos are not very good and I can't figure anything out from the Excel documentation.
Could you help me write the code and give me any references I can use as back up and so I can learn. I'm a complete beginner to Windows Excel VBA and a low intermediate with Excel. Thank you

Resources