Click here to Skip to main content
15,899,754 members
Home / Discussions / C#
   

C#

 
GeneralRe: Windows Forms Pin
Martin#27-Mar-07 3:40
Martin#27-Mar-07 3:40 
AnswerRe: Windows Forms Pin
Martin#27-Mar-07 3:36
Martin#27-Mar-07 3:36 
QuestionLarge TXT files Pin
Sabry190527-Mar-07 3:04
Sabry190527-Mar-07 3:04 
AnswerRe: Large TXT files Pin
Christian Graus27-Mar-07 3:13
protectorChristian Graus27-Mar-07 3:13 
AnswerRe: Large TXT files Pin
hakonvik27-Mar-07 3:22
hakonvik27-Mar-07 3:22 
GeneralRe: Large TXT files Pin
Christian Graus27-Mar-07 3:36
protectorChristian Graus27-Mar-07 3:36 
GeneralRe: Large TXT files Pin
Sabry190527-Mar-07 5:12
Sabry190527-Mar-07 5:12 
GeneralRe: Large TXT files Pin
Dan Neely27-Mar-07 5:24
Dan Neely27-Mar-07 5:24 
Is txtFileContent a string or a StringBuilder? IF the former replacing it with the latter will see a massive performance boost. A string is immutable, which means each time you do txtFileContent.AppendText(line); you're creating a new string and copying the old one to it. For normal use immutable strings allow certain optimizations that result in faster code, but when building a really large string they absolutely murder performance. IF you;re using a string for each line of your file you're copying everything read so far three times. And absolutely thrashing the GC in the process.



--
CleaKO The sad part about this instance is that none of the users ever said anything [about the problem].

Pete O`Hanlon Doesn't that just tell you everything you need to know about users?

GeneralRe: Large TXT files Pin
Sabry190527-Mar-07 5:51
Sabry190527-Mar-07 5:51 
GeneralRe: Large TXT files Pin
Dan Neely27-Mar-07 6:52
Dan Neely27-Mar-07 6:52 
AnswerUse a FileStream Pin
Ennis Ray Lynch, Jr.27-Mar-07 5:14
Ennis Ray Lynch, Jr.27-Mar-07 5:14 
QuestionMotorola S-Record file to Binary file Pin
-=gix=-27-Mar-07 2:02
-=gix=-27-Mar-07 2:02 
AnswerRe: Motorola S-Record file to Binary file Pin
Colin Angus Mackay27-Mar-07 2:25
Colin Angus Mackay27-Mar-07 2:25 
GeneralRe: Motorola S-Record file to Binary file Pin
-=gix=-27-Mar-07 3:10
-=gix=-27-Mar-07 3:10 
GeneralRe: Motorola S-Record file to Binary file Pin
Colin Angus Mackay27-Mar-07 12:35
Colin Angus Mackay27-Mar-07 12:35 
GeneralRe: Motorola S-Record file to Binary file Pin
-=gix=-29-Mar-07 20:11
-=gix=-29-Mar-07 20:11 
QuestionSharing a folder with users programmatically Pin
wasife27-Mar-07 1:23
wasife27-Mar-07 1:23 
QuestionConsole the text that user keyin in text box to another window form . Pin
krajah1027-Mar-07 0:06
krajah1027-Mar-07 0:06 
AnswerRe: Console the text that user keyin in text box to another window form . Pin
Colin Angus Mackay27-Mar-07 0:37
Colin Angus Mackay27-Mar-07 0:37 
QuestionRead password from text file and compare with user textbox input Pin
krajah1026-Mar-07 23:56
krajah1026-Mar-07 23:56 
AnswerRe: Read password from text file and compare with user textbox input Pin
Balaji Prabu AL27-Mar-07 1:06
Balaji Prabu AL27-Mar-07 1:06 
GeneralRe: Read password from text file and compare with user textbox input Pin
krajah1027-Mar-07 4:34
krajah1027-Mar-07 4:34 
QuestionRe: Read password from text file and compare with user textbox input Pin
Balaji Prabu AL27-Mar-07 6:44
Balaji Prabu AL27-Mar-07 6:44 
AnswerRe: Read password from text file and compare with user textbox input Pin
krajah1027-Mar-07 21:59
krajah1027-Mar-07 21:59 
GeneralRe: Read password from text file and compare with user textbox input Pin
ak2029-Aug-09 21:21
ak2029-Aug-09 21:21 

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.