Click here to Skip to main content
15,890,438 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
good Day can any one teach me how give me a tip how to trace if records is already in the in listview , i currently use listview in Vb.net 2008 Windows Application and i currently use a For Loop that reads all Records in listview to validate if the records is in the listview , but my problem is if records
is in the the listview is already Exist this Records
for Ex:" SAMPLE RECORD" , to "Sample Record"
my validation code not trace this one "Sample Record"
or technically speaking they not trace the similarity of CAPITAL CHARACTER to Normal CHARACTER :( Thanks to all Coders Here :D
Posted

If your problem is checking equivalent strings without regard to case, then compare both strings converted to upper case.
 
Share this answer
 
Comments
Philippe Mori 6-Sep-11 21:34pm    
Or use a case-insensitive comparison...
For comparison you do not need to use a For loop, use DataView.RowFilter(string) with the comparison value and use DataView.Count() to check if there is a match or not.

http://msdn.microsoft.com/en-us/library/system.data.dataview.rowfilter.aspx[^]

hope it helps.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900