diff options
Diffstat (limited to 'src/samples/Dtf/Documents/Guide/Content/debuggingcas.htm')
-rw-r--r-- | src/samples/Dtf/Documents/Guide/Content/debuggingcas.htm | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/src/samples/Dtf/Documents/Guide/Content/debuggingcas.htm b/src/samples/Dtf/Documents/Guide/Content/debuggingcas.htm new file mode 100644 index 00000000..ca1be161 --- /dev/null +++ b/src/samples/Dtf/Documents/Guide/Content/debuggingcas.htm | |||
@@ -0,0 +1,66 @@ | |||
1 | <html xmlns="http://www.w3.org/1999/xhtml"> | ||
2 | <head> | ||
3 | <title>Debugging Managed Custom Actions</title> | ||
4 | <link rel="stylesheet" type="text/css" href="../styles/presentation.css" /> | ||
5 | <link rel="stylesheet" type="text/css" href="ms-help://Hx/HxRuntime/HxLink.css" /> | ||
6 | </head> | ||
7 | |||
8 | <body> | ||
9 | |||
10 | <div id="control"> | ||
11 | <span class="productTitle">Deployment Tools Foundation</span><br /> | ||
12 | <span class="topicTitle">Debugging Managed Custom Actions</span><br /> | ||
13 | <div id="toolbar"> | ||
14 | <span id="chickenFeet"> | ||
15 | <a href="using.htm">Development Guide</a> > | ||
16 | <a href="managedcas.htm">Managed CAs</a> > | ||
17 | <span class="nolink">Debugging</span> | ||
18 | </span> | ||
19 | </div> | ||
20 | </div> | ||
21 | <div id="main"> | ||
22 | <div id="header"> | ||
23 | </div> | ||
24 | <div class="summary"> | ||
25 | <p>There are two ways to attach a debugger to a managed custom action.</p> | ||
26 | <p><b>Attach to message-box:</b> Add some temporary code to your custom action to display a | ||
27 | message box. Then when the message box pops up at install time, you can attch your | ||
28 | debugger to that process (usually identifiable by the title of the message box). | ||
29 | Once attached, you can ensure that symbols are loaded if necessary (they will be automatically | ||
30 | loaded if PDB files were embedded in the CA assembly at build time), then set breakpoints | ||
31 | anywhere in the custom action code.</p> | ||
32 | <p><b>MMsiBreak environment variable:</b> When debugging <i>managed</i> custom actions, | ||
33 | you should use the MMsiBreak environment variable instead of MsiBreak. Set the MMsiBreak | ||
34 | variable to the custom action entrypoint name. (Remember this might be different from | ||
35 | the method name if it was overridden by the CustomActionAttribute.) When the CA proxy | ||
36 | finds a matching name, the CLR JIT-debugging dialog | ||
37 | will appear with text similar to "An exception 'Launch for user' has occurred | ||
38 | in <i>YourCustomActionName</i>." The debug break occurs after the custom | ||
39 | action assembly has been loaded, but just before custom action method is invoked. | ||
40 | Once attached, you can ensure that symbols are loaded if necessary, | ||
41 | then set breakpoints anywhere in the custom action code. Note: the MMsiBreak | ||
42 | environment variable can also accept a comma-separated list of action names, any of | ||
43 | which will cause a break when hit.</p> | ||
44 | <p><br/></p> | ||
45 | |||
46 | </div> | ||
47 | |||
48 | <div id="footer"> | ||
49 | <p /> | ||
50 | Send comments on this topic to <a id="HT_MailLink" href="mailto:wix-users%40lists.sourceforge.net?Subject=Deployment Tools Foundation Documentation"> | ||
51 | wix-users@lists.sourceforge.net</a> | ||
52 | |||
53 | <script type="text/javascript"> | ||
54 | var HT_mailLink = document.getElementById("HT_MailLink"); | ||
55 | var HT_mailLinkText = HT_mailLink.innerHTML; | ||
56 | HT_mailLink.href += ": " + document.title; | ||
57 | HT_mailLink.innerHTML = HT_mailLinkText; | ||
58 | </script> | ||
59 | |||
60 | <p /> | ||
61 | |||
62 | </div> | ||
63 | </div> | ||
64 | |||
65 | </body> | ||
66 | </html> | ||