PuntingJawa
Board Regular
- Joined
- Feb 25, 2021
- Messages
- 140
- Office Version
- 365
- 2019
- Platform
- Windows
I'm messing with UserForm to make input for receiving and shipping information a little easier. My question is the following. Is there a way for me to have the input generated where for packing slips to show PS before the submission of the packing slip number input.
Example:
I have the following UserForm made up. For Pack No. and PO. I would like to have "PS " and "PO " before the numbers submitted on their lines without having to add PS and PO manually. Is this at all possible?
Example:
I have the following UserForm made up. For Pack No. and PO. I would like to have "PS " and "PO " before the numbers submitted on their lines without having to add PS and PO manually. Is this at all possible?
VBA Code:
Private Sub UserForm_Activate()
TextBox1.Text = Format(Now(), "MM/DD/YY")
End Sub
Private Sub CommandButton1_Click()
erow = Sheets("Sheet1").Range("a" & Rows.Count).End(xlUp).Row
Range("A" & erow + 1) = TextBox1.Value
Range("B" & erow + 1) = TextBox2.Value
Range("C" & erow + 1) = TextBox3.Value
Range("D" & erow + 1) = TextBox4.Value
Range("E" & erow + 1) = TextBox5.Value
Range("F" & erow + 1) = TextBox6.Value
Range("G" & erow + 1) = TextBox7.Value
Range("I" & erow + 1) = TextBox8.Value
Range("J" & erow + 1) = TextBox9.Value
Range("K" & erow + 1) = TextBox10.Value
Range("L" & erow + 1) = TextBox11.Value
TextBox2.Value = ""
TextBox3.Value = ""
TextBox4.Value = ""
TextBox5.Value = ""
TextBox6.Value = ""
TextBox7.Value = ""
TextBox8.Value = ""
TextBox9.Value = ""
TextBox10.Value = ""
TextBox11.Value = ""
End Sub