Help with coding command button in user form

monsta7144

New Member
Joined
Apr 6, 2015
Messages
3
Hello,

Firstly, this is my first time posting so i apologize if this is in the wrong place. I have a spreadsheet for fuel issues for equipment with the equipment in row 1 and the date in column A as such:

[TABLE="width: 250"]
<tbody>[TR]
[TD][/TD]
[TD]D1[/TD]
[TD]D2[/TD]
[TD]D3[/TD]
[/TR]
[TR]
[TD]01/04[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]02/04[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

I am trying to create a user form to enter the data as the sheet is quite large. The userform looks like this,

date (text box)
Select vehicle (combobox)
Enter fuel amount (text)
Enter data (command button)

I am failing to find any code to use in the command button as i have only very basic knowledge of VBA so that when it's clicked, it uses the date and the vehicle selection to put the fuel amount into the right cell. Any assistancewould be greatly appreciated
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.

Forum statistics

Threads
1,223,228
Messages
6,170,871
Members
452,363
Latest member
merico17

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