![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
From: mensikd (AT) seznam (DOT) cz (David Mensik) Newsgroups: microsoft.public.dotnet.framework.clr Subject: How to obtain argument values in runtime? Date: 7 Jul 2003 04:55:52 -0700 Organization: http://groups.google.com/ Lines: 32 Message-ID: <3e043eb8.0307070355.5f1a0c35 (AT) posting (DOT) google.com NNTP-Posting-Host: 158.194.200.44 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1057578952 19918 127.0.0.1 (7 Jul 2003 11:55:52 GMT) X-Complaints-To: groups-abuse (AT) google (DOT) com NNTP-Posting-Date: 7 Jul 2003 11:55:52 GMT Path: cpmsftngxa09.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed 00.sul.t-online.de!t-onlin |
|
Xref: cpmsftngxa09.phx.gbl microsoft.public.dotnet.framework.clr:1350 X-Tomcat-NG: microsoft.public.dotnet.framework.clr Hi, can you please help me by obtaining methods argument values in runtime? I have this construction: --- source code --- try { someobject.somemethod(someargumentvalue); } catch(Exception exc) { ShowStack(exc) } public static void ShowStack(Exception exc) { StakTrace loTrace = new StackTrace(exc,true); StackFrame loFrame = loTrace.GetFrame(loTrace.FrameCount - 1); ... //now I'm displaying some infos about function, in which exception occured. //everything is OK, but how can I got the values of methods arguments? } --- source code --- So question is: "When I can get function name, line number, parameters name etc. but I can't get parameters value which were in stack frame by raising exception. How can I get those values? Thanks for advice, David Mensik |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |