Update Text Field Based on Combo Box Field

QandAdam

New Member
Joined
Jan 12, 2019
Messages
30
On a Form, there is a Combo Box Field which lists different Statuses (e.g. Open, Pending, Closed).

Is it possible for the following to happen?

When 'Status' is changed from 'Open', add the sentence to the end of the text field 'Comments' to be something like this:
"05/05/19 - Closed - J.Smith"
(Date Status Changed) - (New Status) - (Current User)
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Yes, put come code in the AfterUpdate event of the combo
Code:
Me.Comment = me.Comment & " " & Me.CloseDate & " - " & Me.cboStatus.Column(1) & " - " & Me.CurrentUser

You would need to check if an entry already existed though, or perhaps disable the Status combo?
I am also assuming that the combo has two columns, an ID and descriptive value?
HTH
 
Upvote 0
Yes, put come code in the AfterUpdate event of the combo
Code:
Me.Comment = me.Comment & " " & Me.CloseDate & " - " & Me.cboStatus.Column(1) & " - " & Me.CurrentUser

You would need to check if an entry already existed though, or perhaps disable the Status combo?
I am also assuming that the combo has two columns, an ID and descriptive value?
HTH

Is there a way which this could only run if the value changed from "Open" to a different value? (Also the combo only has the one column - the description)
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,178
Members
453,021
Latest member
Justyna P

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