Click here to Skip to main content
15,888,233 members
Home / Discussions / C#
   

C#

 
GeneralRe: disabling particular item in a checked list box Pin
Swiftain25-Mar-10 22:50
Swiftain25-Mar-10 22:50 
QuestionMessage Removed Pin
25-Mar-10 20:29
Punit Belani25-Mar-10 20:29 
GeneralRe: clear form data (only IE problem) Pin
thatraja25-Mar-10 20:33
professionalthatraja25-Mar-10 20:33 
GeneralRe: clear form data (only IE problem) Pin
Punit Belani25-Mar-10 20:36
Punit Belani25-Mar-10 20:36 
GeneralRe: clear form data (only IE problem) Pin
thatraja25-Mar-10 20:58
professionalthatraja25-Mar-10 20:58 
QuestionControls and Context Menu question from a newbie. Pin
Kanetakeo25-Mar-10 20:01
Kanetakeo25-Mar-10 20:01 
AnswerRe: Controls and Context Menu question from a newbie. Pin
OriginalGriff25-Mar-10 22:38
mveOriginalGriff25-Mar-10 22:38 
QuestionProblem in datatable class select function with special characters Pin
abcurl25-Mar-10 18:06
abcurl25-Mar-10 18:06 
I am facing a problem while filtering using the datatable class select function.

Following is the code.

DataTable dt;
DataRow dr ;
        
dt = New DataTable()
dt.Columns.Add("t", System.Type.GetType("System.String"));
dr = dt.NewRow();
dr["t"] = "12";
dt.Rows.Add(dr);


Dim search As String

'There is no problem when i write the following search string
search = "~!@#$%^&*"


dt.Select("t like '%" + search.Replace("%", "[%]").Replace("'", "''") + "%'");


but problem comes when i append a special character ( with the search

search = "~!@#$%^&*(";


dt.Select("t like '%" + search.Replace("%", "[%]").Replace("'", "''") + "%'");


Error message is
Error in Like operator: the string pattern '%~!@#$[%]^&*(%' is invalid.
AnswerRe: Problem in datatable class select function with special characters Pin
Abhinav S25-Mar-10 18:28
Abhinav S25-Mar-10 18:28 
QuestionA Car Horn for my Robot Pin
sebogawa25-Mar-10 16:16
sebogawa25-Mar-10 16:16 
AnswerRe: A Car Horn for my Robot Pin
Khaniya25-Mar-10 19:03
professionalKhaniya25-Mar-10 19:03 
AnswerRe: A Car Horn for my Robot Pin
Som Shekhar25-Mar-10 19:48
Som Shekhar25-Mar-10 19:48 
QuestionStoring a high score list Pin
The Cake of Deceit25-Mar-10 13:53
The Cake of Deceit25-Mar-10 13:53 
AnswerRe: Storing a high score list Pin
PIEBALDconsult25-Mar-10 13:59
mvePIEBALDconsult25-Mar-10 13:59 
AnswerRe: Storing a high score list Pin
Luc Pattyn25-Mar-10 14:00
sitebuilderLuc Pattyn25-Mar-10 14:00 
GeneralRe: Storing a high score list Pin
The Cake of Deceit25-Mar-10 14:10
The Cake of Deceit25-Mar-10 14:10 
GeneralRe: Storing a high score list Pin
Luc Pattyn25-Mar-10 14:34
sitebuilderLuc Pattyn25-Mar-10 14:34 
GeneralRe: Storing a high score list Pin
PIEBALDconsult25-Mar-10 15:10
mvePIEBALDconsult25-Mar-10 15:10 
GeneralRe: Storing a high score list Pin
Luc Pattyn25-Mar-10 15:13
sitebuilderLuc Pattyn25-Mar-10 15:13 
GeneralRe: Storing a high score list Pin
PIEBALDconsult25-Mar-10 16:13
mvePIEBALDconsult25-Mar-10 16:13 
GeneralRe: Storing a high score list Pin
Luc Pattyn25-Mar-10 16:23
sitebuilderLuc Pattyn25-Mar-10 16:23 
GeneralRe: Storing a high score list Pin
The Cake of Deceit26-Mar-10 4:21
The Cake of Deceit26-Mar-10 4:21 
GeneralRe: Storing a high score list Pin
Not Active25-Mar-10 14:40
mentorNot Active25-Mar-10 14:40 
GeneralRe: Storing a high score list Pin
DaveyM6925-Mar-10 15:04
professionalDaveyM6925-Mar-10 15:04 
GeneralRe: Storing a high score list Pin
fuad_200025-Mar-10 22:15
fuad_200025-Mar-10 22:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.