troubleshooting Question

MS Access Array Query

Avatar of lankapala
lankapala asked on
Microsoft AccessSQL
3 Comments1 Solution317 ViewsLast Modified:
My query coding is below
Function SplitNames(Val as String) as String
Dim arr1 As Variant
arr1  = Array("Mr","Mrs","Dr")
Dim count as integer
count=0
while count<=2
if(val<>arr1(count)) then
SplitNames=val
end if

count=count+1
wend

end function

Above my coding is working perfect in the eqaul(if(val=arr1(count)) then) BUT its not working in Not equal. I need to my out put be not Mr or Mrs or Dr.
Please help me to solve above my issue.
When iam using most of the time Not equal is not working <>




ASKER CERTIFIED SOLUTION
harfang

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 3 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros