Click here to Skip to main content
15,911,646 members
Home / Discussions / C#
   

C#

 
AnswerRe: change ip address Pin
EliottA2-Feb-09 16:21
EliottA2-Feb-09 16:21 
AnswerRe: change ip address Pin
N a v a n e e t h2-Feb-09 17:21
N a v a n e e t h2-Feb-09 17:21 
GeneralRe: change ip address Pin
Waheed Ur Rehman2-Feb-09 23:56
Waheed Ur Rehman2-Feb-09 23:56 
GeneralRe: change ip address Pin
N a v a n e e t h3-Feb-09 4:43
N a v a n e e t h3-Feb-09 4:43 
GeneralRe: change ip address Pin
Waheed Ur Rehman15-Feb-09 4:12
Waheed Ur Rehman15-Feb-09 4:12 
Question.NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Ryan Neil Shaw2-Feb-09 12:43
Ryan Neil Shaw2-Feb-09 12:43 
AnswerRe: .NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Christian Graus2-Feb-09 13:04
protectorChristian Graus2-Feb-09 13:04 
AnswerRe: .NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Guffa2-Feb-09 14:49
Guffa2-Feb-09 14:49 
The performance of a regular expression depends on how you write it, i.e. how many comparisons and backtracks it has to do to get the result.

For example, the pattern "A.+Z" looks for an A, then .+ matches the rest of the string. That means it has to backtrack by reducing what .+ matches a character at a time until it can find a match for Z also. The pattern "A.+?Z" looks for an A, then it starts by matching the non-greedy expression .+? against a single character, increasing the match until it finds the Z.

If you are not careful with greedy quantifiers and what you match, you end up searching most of the string many times over.

Despite everything, the person most likely to be fooling you next is yourself.

GeneralRe: .NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Ryan Neil Shaw3-Feb-09 5:52
Ryan Neil Shaw3-Feb-09 5:52 
GeneralRe: .NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Guffa3-Feb-09 7:05
Guffa3-Feb-09 7:05 
GeneralRe: .NET C# RegEx - Poor Perfomance - Suggested Alternative? Pin
Ryan Neil Shaw3-Feb-09 11:55
Ryan Neil Shaw3-Feb-09 11:55 
QuestionString to Type Keys. Pin
zetrixfire2-Feb-09 12:36
zetrixfire2-Feb-09 12:36 
AnswerRe: String to Type Keys. Pin
Christian Graus2-Feb-09 13:06
protectorChristian Graus2-Feb-09 13:06 
AnswerRe: String to Type Keys. Pin
Guffa2-Feb-09 13:32
Guffa2-Feb-09 13:32 
QuestionSerialization in practice..When? Pin
bolly-812-Feb-09 10:40
bolly-812-Feb-09 10:40 
AnswerRe: Serialization in practice..When? Pin
Christian Graus2-Feb-09 10:48
protectorChristian Graus2-Feb-09 10:48 
AnswerRe: Serialization in practice..When? Pin
PIEBALDconsult2-Feb-09 12:11
mvePIEBALDconsult2-Feb-09 12:11 
QuestionRead in text file Pin
alwaysthinking2-Feb-09 9:42
alwaysthinking2-Feb-09 9:42 
AnswerRe: Read in text file Pin
Natza Mitzi2-Feb-09 10:15
Natza Mitzi2-Feb-09 10:15 
QuestionPrint a DataGridView Pin
Jordanwb2-Feb-09 8:43
Jordanwb2-Feb-09 8:43 
AnswerRe: Print a DataGridView Pin
Christian Graus2-Feb-09 8:52
protectorChristian Graus2-Feb-09 8:52 
GeneralRe: Print a DataGridView Pin
Jordanwb2-Feb-09 8:58
Jordanwb2-Feb-09 8:58 
GeneralRe: Print a DataGridView Pin
Duncan Edwards Jones2-Feb-09 11:41
professionalDuncan Edwards Jones2-Feb-09 11:41 
Questionpain Datagrid row in color - WinCE Pin
E_Gold2-Feb-09 8:37
E_Gold2-Feb-09 8:37 
AnswerRe: pain Datagrid row in color - WinCE Pin
EliottA2-Feb-09 8:45
EliottA2-Feb-09 8:45 

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.