EDN Admin
Well-known member
<p align=left><font face=Arial size=2></font>
Hi,
I have a program that was originally in VB that I am trying to convert to <a class=iAs style="font-weight:normal! important;font-size:100%! important;padding-bottom:1px! important;color:darkgreen! important;border-bottom:darkgreen 0.07em solid;background-color:transparent! important;text-decoration:underline! important http://www.daniweb.com/forums/thread125420.html# C# . I have converted all of it succesfully accept for a part that uses the "like" statement.
The program starts off by having the user enter a file name that they want to work with, then clicking a button so that the file is uploaded and stored in an array. The user can then type in a peice of information into a textbox, click a button, and have the <a class=iAs style="font-weight:normal! important;font-size:100%! important;padding-bottom:1px! important;color:darkgreen! important;border-bottom:darkgreen 0.07em solid;background-color:transparent! important;text-decoration:underline! important http://www.daniweb.com/forums/thread125420.html# app display a peice of information from the datafile based on what they typed in.
The piece that I am trying to convert looks like this:
For x = 0 To n - 1
With order(x)
If .buyername Like TextBox3.Text & "*" Then
Label5.Text = .title
End If
If .sellername Like TextBox3.Text & "*" Then
Label5.Text = .title
End If
End With
Next
Ive looked into many comparisons between VB and C# to see how a process like this could be accomplished in C# and havent found anything. Any suggestions would be greatly appreciated.
View the full article
Hi,
I have a program that was originally in VB that I am trying to convert to <a class=iAs style="font-weight:normal! important;font-size:100%! important;padding-bottom:1px! important;color:darkgreen! important;border-bottom:darkgreen 0.07em solid;background-color:transparent! important;text-decoration:underline! important http://www.daniweb.com/forums/thread125420.html# C# . I have converted all of it succesfully accept for a part that uses the "like" statement.
The program starts off by having the user enter a file name that they want to work with, then clicking a button so that the file is uploaded and stored in an array. The user can then type in a peice of information into a textbox, click a button, and have the <a class=iAs style="font-weight:normal! important;font-size:100%! important;padding-bottom:1px! important;color:darkgreen! important;border-bottom:darkgreen 0.07em solid;background-color:transparent! important;text-decoration:underline! important http://www.daniweb.com/forums/thread125420.html# app display a peice of information from the datafile based on what they typed in.
The piece that I am trying to convert looks like this:
For x = 0 To n - 1
With order(x)
If .buyername Like TextBox3.Text & "*" Then
Label5.Text = .title
End If
If .sellername Like TextBox3.Text & "*" Then
Label5.Text = .title
End If
End With
Next
Ive looked into many comparisons between VB and C# to see how a process like this could be accomplished in C# and havent found anything. Any suggestions would be greatly appreciated.
View the full article