Click here to Skip to main content
15,893,190 members
Home / Discussions / C#
   

C#

 
QuestionVGA output in C# Pin
evertqin18-Nov-08 9:47
evertqin18-Nov-08 9:47 
AnswerRe: VGA output in C# Pin
Dan Neely18-Nov-08 10:05
Dan Neely18-Nov-08 10:05 
GeneralRe: VGA output in C# Pin
evertqin18-Nov-08 14:22
evertqin18-Nov-08 14:22 
GeneralRe: VGA output in C# Pin
Dave Kreskowiak18-Nov-08 14:33
mveDave Kreskowiak18-Nov-08 14:33 
GeneralRe: VGA output in C# Pin
evertqin18-Nov-08 17:02
evertqin18-Nov-08 17:02 
GeneralRe: VGA output in C# Pin
Dave Kreskowiak18-Nov-08 17:42
mveDave Kreskowiak18-Nov-08 17:42 
AnswerRe: VGA output in C# Pin
Christian Graus18-Nov-08 11:47
protectorChristian Graus18-Nov-08 11:47 
Questionregular expression cleanup! Pin
nesfrank18-Nov-08 9:14
nesfrank18-Nov-08 9:14 
hi guys, I need to clean up a string what this function below does but sometimes this is too slow and I have been told that for best performance regular expression will do much a faster job. Is there anyway to write a regulatr expression that cleans what the function below does?

Please help guys!

Thanks
Frank

private string CleanString(string strValue)
{

// See Above CString() Function for ASCii Denotations.
string strReturn = strValue;
for(int x=0; x < strValue.Length; x++)
{
char charTmp = strValue[x];
string strTmp = charTmp.ToString();
int ASCii = (int)charTmp;
// The following blocks system characters (<= 31) save for the
// CR (10) / LF (13) needed to preserve Line Returns. It also clears
// some specific problematic characters, such as double quotes ("),
// semi-colons (;) and html-tag delimiters (<) and (>).
if ( (ASCii <=9) || (ASCii == 11) || (ASCii == 12) || ( (ASCii >=14) && (ASCii <=31) ) || (ASCii == 34) || (ASCii == 59) || (ASCii == 60) || (ASCii == 62) || (ASCii == 124) )
{
// Strip out these characters as they're encountered...
strReturn = strReturn.Replace(strTmp, "");
}
// This next step eliminates the ever-annoying shift-space character
// as well as a large range of non-used symbol and system characters.
if ( ((ASCii >=127) && (ASCii >= 191)) || (ASCii == 215) || (ASCii == 247) )
{
// Strip out these characters...
strReturn = strReturn.Replace(strTmp, "");
}
}

return strReturn;
}
AnswerRe: regular expression cleanup! Pin
sph3rex18-Nov-08 9:34
sph3rex18-Nov-08 9:34 
AnswerRe: regular expression cleanup! Pin
carbon_golem18-Nov-08 9:54
carbon_golem18-Nov-08 9:54 
AnswerRe: regular expression cleanup! Pin
Garth J Lancaster18-Nov-08 10:17
professionalGarth J Lancaster18-Nov-08 10:17 
AnswerRe: regular expression cleanup! [modified] Pin
Robert.C.Cartaino18-Nov-08 11:16
Robert.C.Cartaino18-Nov-08 11:16 
QuestionDataset with 6 columns, how to display only 3 in a data grid? Pin
jeweladdict18-Nov-08 9:06
jeweladdict18-Nov-08 9:06 
AnswerRe: Dataset with 6 columns, how to display only 3 in a data grid? Pin
Wendelius18-Nov-08 9:39
mentorWendelius18-Nov-08 9:39 
AnswerRe: Dataset with 6 columns, how to display only 3 in a data grid? Pin
Priya Prk18-Nov-08 9:40
Priya Prk18-Nov-08 9:40 
GeneralRe: Dataset with 6 columns, how to display only 3 in a data grid? Pin
jeweladdict18-Nov-08 9:47
jeweladdict18-Nov-08 9:47 
Questionthoughts on localizing SQL exceptions? Pin
Member 232448318-Nov-08 8:46
Member 232448318-Nov-08 8:46 
AnswerRe: thoughts on localizing SQL exceptions? Pin
Wendelius18-Nov-08 9:17
mentorWendelius18-Nov-08 9:17 
GeneralRe: thoughts on localizing SQL exceptions? Pin
Member 232448318-Nov-08 9:39
Member 232448318-Nov-08 9:39 
GeneralRe: thoughts on localizing SQL exceptions? Pin
Wendelius18-Nov-08 9:47
mentorWendelius18-Nov-08 9:47 
GeneralRe: thoughts on localizing SQL exceptions? Pin
Member 232448318-Nov-08 10:15
Member 232448318-Nov-08 10:15 
GeneralRe: thoughts on localizing SQL exceptions? Pin
Wendelius18-Nov-08 10:34
mentorWendelius18-Nov-08 10:34 
QuestionSpecifying pointer address, or something like that... Pin
boberick218-Nov-08 8:08
boberick218-Nov-08 8:08 
AnswerRe: Specifying pointer address, or something like that... Pin
Dave Kreskowiak18-Nov-08 8:21
mveDave Kreskowiak18-Nov-08 8:21 
GeneralRe: Specifying pointer address, or something like that... Pin
boberick218-Nov-08 8:37
boberick218-Nov-08 8:37 

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.