Click here to Skip to main content
15,887,446 members
Home / Discussions / C#
   

C#

 
QuestionParse a FlatFile with Multiline using BizTalk Pin
Ahmed Abdelnasser4-Sep-13 0:57
Ahmed Abdelnasser4-Sep-13 0:57 
QuestionWebsite visit automation script Pin
Neo101014-Sep-13 0:09
Neo101014-Sep-13 0:09 
AnswerRe: Website visit automation script Pin
Richard MacCutchan4-Sep-13 4:52
mveRichard MacCutchan4-Sep-13 4:52 
QuestionPrinting a bill format Pin
prerana patil3-Sep-13 22:59
prerana patil3-Sep-13 22:59 
AnswerRe: Printing a bill format Pin
OriginalGriff3-Sep-13 23:30
mveOriginalGriff3-Sep-13 23:30 
QuestionDaft question on indenting text. Pin
Septimus Hedgehog3-Sep-13 5:21
Septimus Hedgehog3-Sep-13 5:21 
GeneralRe: Daft question on indenting text. Pin
harold aptroot3-Sep-13 5:36
harold aptroot3-Sep-13 5:36 
AnswerRe: Daft question on indenting text. Pin
Dave Kreskowiak3-Sep-13 5:37
mveDave Kreskowiak3-Sep-13 5:37 
It's doable, but not practical.

Every one of your methods that participates in this scheme would have to pass around a "depth" field. Every time a method that uses this field is called, it would have to pass the current depth to the next method, where one of the first things the callee does is increment the depth.

I'm not liking this as is neccessitates passing an extra value into each method and each method would have to be custom implemented to support this, possibly interfering with your logic, but certainly adding a bit more complexity and duplication in your code.

I don't see any other way to do this, but I could be wrong.

[EDIT]
I just thought of something. You might be able to use the StackTrace for the current depth in some logging component, but don't count on it being accurate as you'll also be counting depth into calls that do not belong to your code.

AnswerRe: Daft question on indenting text. Pin
Septimus Hedgehog3-Sep-13 5:58
Septimus Hedgehog3-Sep-13 5:58 
AnswerRe: Daft question on indenting text. Pin
jschell3-Sep-13 12:40
jschell3-Sep-13 12:40 
GeneralRe: Daft question on indenting text. Pin
Septimus Hedgehog3-Sep-13 20:36
Septimus Hedgehog3-Sep-13 20:36 
AnswerRe: Daft question on indenting text. Pin
BillWoodruff3-Sep-13 17:24
professionalBillWoodruff3-Sep-13 17:24 
GeneralRe: Daft question on indenting text. Pin
Septimus Hedgehog3-Sep-13 20:45
Septimus Hedgehog3-Sep-13 20:45 
GeneralRe: Daft question on indenting text. Pin
BillWoodruff3-Sep-13 23:29
professionalBillWoodruff3-Sep-13 23:29 
GeneralRe: Daft question on indenting text. Pin
Septimus Hedgehog4-Sep-13 0:35
Septimus Hedgehog4-Sep-13 0:35 
GeneralRe: Daft question on indenting text. Pin
BillWoodruff4-Sep-13 3:52
professionalBillWoodruff4-Sep-13 3:52 
GeneralRe: Daft question on indenting text. Pin
Septimus Hedgehog4-Sep-13 6:00
Septimus Hedgehog4-Sep-13 6:00 
AnswerRe: Daft question on indenting text. Pin
Bernhard Hiller3-Sep-13 22:40
Bernhard Hiller3-Sep-13 22:40 
GeneralRe: Daft question on indenting text. Pin
Septimus Hedgehog4-Sep-13 0:15
Septimus Hedgehog4-Sep-13 0:15 
QuestionSubstring / Split String help Pin
Member 101198373-Sep-13 5:02
Member 101198373-Sep-13 5:02 
AnswerRe: Substring / Split String help Pin
Dave Kreskowiak3-Sep-13 5:30
mveDave Kreskowiak3-Sep-13 5:30 
GeneralRe: Substring / Split String help Pin
Member 101198373-Sep-13 5:39
Member 101198373-Sep-13 5:39 
GeneralRe: Substring / Split String help Pin
Dave Kreskowiak3-Sep-13 5:47
mveDave Kreskowiak3-Sep-13 5:47 
AnswerRe: Substring / Split String help Pin
BillWoodruff3-Sep-13 17:46
professionalBillWoodruff3-Sep-13 17:46 
AnswerRe: Substring / Split String help Pin
Forbiddenx4-Sep-13 4:59
Forbiddenx4-Sep-13 4:59 

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.