Link to home
Start Free TrialLog in
Avatar of LozLaura17
LozLaura17

asked on

Validating A textbox in a UserForm

I have created a User Form that will allow you to enter and search details.  It will then enter these details into a spreadsheet via a save button.  There are three things I would then Like to do

1.  I would like to be able to update details rather than have to press save each time and get a new line
2.  I would like to be able to search and delete a file rather than having to search and manually delete
3.  Finally I have two text fields that allow information to be entered into them but I also before allowing me to press the save   button i need the to validate the field to check that the same information has not already been entered

My Userform has 11 fields (A-K)

A Text Field (This is used to search) This needs to be validated to only allow non duplicate information to be entered
B Text Field (This is used to search) This needs to be validated to only allow non duplicate information to be entered
c Combo Box
d Combo Box
e Option Buttons
f Text Box
g Option Button
h Option Button
i Option Button
j Combo box
k Combo box
   
ASKER CERTIFIED SOLUTION
Avatar of manthanein
manthanein

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of LozLaura17
LozLaura17

ASKER

My save function will take all the values that are entered into the userform and put them in a spreadsheet. I now need to write a function that will allow me to use my search function (search by column A OR B and then show rest of information from that row into the userform) to get up the current information on that record and then edit some of the information and resave those detail.  At the moment all it will do is enter these details as a current row or say that they are duplicate
The only thing I can think of with regards to not duplicationg searches is to use a combobox and there is an option in the propertys that will not allow duplicate values to be in there :) Not sure if that helps you any ?
hi LozLaura17  have you tried my code.  I actually  made the search and save capabilities working in there