if ***.delete will delete one record at a time, what deletes all records from a table with a single click of a button. I tried writing a do until eof loop but I get a multistep OLE Db error. Any suggestions?
that woked well thank u. I have another realtively simple question:
if you're checking what values variables hold,for exmaple:
for strings you check if var1=""
for integers we check if var1=0
how do we check for empty DATE values?
I have a situation where I'm checking 2 textboxes to see if they are both empty. I first check a TB that would contain a name and if it's empty I have a nested if to check the other textbox where a date may be place. If the first one has an empty value and the second(date) has an empty value , then there is an input box asking for a date to be entered. However this inputbox has an ok and a cancel button and if either are clicked with nothing entered then I get a type mismatch error. I tried writing a do until (var)<> 0, and continued to get the same result. This is where the question comes in about empty date values. I will include the code so you can see what I'm talking about and assume all variables are dimmed.
thanks adam
txtEmpQry.SetFocus
If txtEmpQry.Text = "" Then
txtPPQry.SetFocus
If txtPPQry.Text = "" Then
answer = MsgBox("Would you like to search by Employee?", vbYesNo)
If answer = 6 Then
input1 = InputBox("Please enter Employees name")
txtEmpQry.SetFocus
txtEmpQry.Text = input1
ElseIf answer = 7 Then
Do While input2 = 0
input2 = InputBox("Please enter Pay Period formatted with short date format xx/xx/xxxx")
Loop
'txtPPQry.SetFocus
'txtPPQry.Text = input2
End If
End If
End If
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.