Click here to Skip to main content
15,891,033 members
Home / Discussions / C#
   

C#

 
AnswerRe: String manipulation with large strings Pin
Rob Philpott8-Apr-09 22:52
Rob Philpott8-Apr-09 22:52 
GeneralRe: String manipulation with large strings Pin
Harvey Saayman8-Apr-09 23:13
Harvey Saayman8-Apr-09 23:13 
GeneralRe: String manipulation with large strings Pin
Rob Philpott8-Apr-09 23:24
Rob Philpott8-Apr-09 23:24 
GeneralRe: String manipulation with large strings Pin
Harvey Saayman8-Apr-09 23:38
Harvey Saayman8-Apr-09 23:38 
GeneralRe: String manipulation with large strings Pin
dojohansen8-Apr-09 23:58
dojohansen8-Apr-09 23:58 
GeneralRe: String manipulation with large strings Pin
Harvey Saayman9-Apr-09 0:30
Harvey Saayman9-Apr-09 0:30 
GeneralRe: String manipulation with large strings Pin
dojohansen9-Apr-09 1:14
dojohansen9-Apr-09 1:14 
GeneralRe: String manipulation with large strings Pin
dojohansen9-Apr-09 1:25
dojohansen9-Apr-09 1:25 
Re-reading your previous postings makes me wonder if what really happens is that your program terminates. I had not noticed that you're calling this on another thread, but depending on how you do this, what type of application it is, and what framework version you are using, it migth be possible.

I don't know all the different possibilities and how they're handled, but I do remember we created threads ourselves in our asp.net application like this: Thread t = new Thread(new ThreadStart(method)); t.Start(); and this actually killed the application if any unhandled exception occured during method. [EDIT] I forgot to say this was on the 1.x Framework and I believe it has changed since. [/EDIT]

In other words, if we invoked String.SubString and passed any invalid arguments, such as a length that requires going beyond the end of the string (try to take 30001 from the 30000 long string), it would immediately terminate the application. I don't remember how VS would behave if debugging this but it seems possible it would just go all blank and not show any messages or anything.

So you should at least test this hypothesis by making sure you wrap the entire method in a try-block and add a catch at the end where you break into the debugger and dump the exception to debug output, like this:

try 
{
    .... 
}
catch (Exception ex)
{
   Debug.WriteLine(ex.ToString());
   Debugger.Break();
}

JokeRe: String manipulation with large strings Pin
dojohansen9-Apr-09 1:37
dojohansen9-Apr-09 1:37 
Questionhow to select the text from the dropdownlist Pin
mdazeemuddin8-Apr-09 22:03
mdazeemuddin8-Apr-09 22:03 
QuestionPenel in Status Bar [modified] Pin
Sajjad Leo8-Apr-09 21:16
Sajjad Leo8-Apr-09 21:16 
AnswerRe: Penel in Status Bar Pin
DaveyM698-Apr-09 22:09
professionalDaveyM698-Apr-09 22:09 
GeneralRe: Penel in Status Bar Pin
Sajjad Leo8-Apr-09 23:19
Sajjad Leo8-Apr-09 23:19 
GeneralRe: Penel in Status Bar Pin
DaveyM699-Apr-09 0:11
professionalDaveyM699-Apr-09 0:11 
GeneralRe: Penel in Status Bar Pin
Sajjad Leo12-Apr-09 20:28
Sajjad Leo12-Apr-09 20:28 
QuestionMedia player control Pin
yesu prakash8-Apr-09 20:44
yesu prakash8-Apr-09 20:44 
AnswerRe: Media player control Pin
12Code8-Apr-09 20:52
12Code8-Apr-09 20:52 
QuestionHelp to me to find simple method for days of month Pin
M Riaz Bashir8-Apr-09 20:30
M Riaz Bashir8-Apr-09 20:30 
AnswerRe: Help to me to find simple method for days of month Pin
DaveyM698-Apr-09 20:37
professionalDaveyM698-Apr-09 20:37 
GeneralRe: Help to me to find simple method for days of month Pin
M Riaz Bashir8-Apr-09 20:39
M Riaz Bashir8-Apr-09 20:39 
QuestionOracle.DataAccess.Client - DbProviderFactories.GetFactory [modified] Pin
devvvy8-Apr-09 20:25
devvvy8-Apr-09 20:25 
AnswerRe: Oracle.DataAccess.Client - DbProviderFactories.GetFactory Pin
devvvy9-Apr-09 16:00
devvvy9-Apr-09 16:00 
Questionproblem with SetSystemTime() fucntion of Kernel32.dll Pin
cppwxwidgetsss8-Apr-09 19:34
cppwxwidgetsss8-Apr-09 19:34 
AnswerRe: problem with SetSystemTime() fucntion of Kernel32.dll Pin
dojohansen9-Apr-09 1:45
dojohansen9-Apr-09 1:45 
GeneralRe: problem with SetSystemTime() fucntion of Kernel32.dll Pin
dojohansen9-Apr-09 1:50
dojohansen9-Apr-09 1:50 

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.