You are on page 1of 181

ComponentOne

DynamicHelp for WinForms

Copyright 1987-2015 GrapeCity, Inc. All rights reserved.

ComponentOne, a division of GrapeCity


201 South Highland Avenue, Third Floor
Pittsburgh, PA 15206 USA

Website:
Sales:
Telephone:

http://www.componentone.com
sales@componentone.com
1.800.858.2739 or 1.412.681.4343 (Pittsburgh, PA USA Office)

Trademarks
The ComponentOne product name is a trademark and ComponentOne is a registered trademark of GrapeCity, Inc.
All other trademarks used herein are the properties of their respective owners.

Warranty
ComponentOne warrants that the media on which the software is delivered is free from defects in material and
workmanship, assuming normal use, for a period of 90 days from the date of purchase. If a defect occurs during this
time, you may return the defective media to ComponentOne, along with a dated proof of purchase, and
ComponentOne will replace it at no charge. After 90 days, you can obtain a replacement for the defective media by
sending it and a check for $25 (to cover postage and handling) to ComponentOne.
Except for the express warranty of the original media on which the software is delivered is set forth here,
ComponentOne makes no other warranties, express or implied. Every attempt has been made to ensure that the
information contained in this manual is correct as of the time it was written. ComponentOne is not responsible for
any errors or omissions. ComponentOnes liability is limited to the amount you paid for the product. ComponentOne
is not liable for any special, consequential, or other damages for any reason.

Copying and Distribution


While you are welcome to make backup copies of the software for your own use and protection, you are not
permitted to make copies for the use of anyone else. We put a lot of time and effort into creating this product, and
we appreciate your support in seeing that it is used by licensed users only.

Table of Contents
DynamicHelp for WinForms Overview ......................................................................................... 8
Help with WinForms Edition ..................................................................................................... 8
Key Features.................................................................................................................................. 8
DynamicHelp for WinForms Samples ........................................................................................... 9
Using DynamicHelp for WinForms .............................................................................................. 11
For Developers: Mapping at Design Time............................................................................... 11
Specifying the Source Help File ........................................................................................... 13
Mapping a Topic to a Control at Design Time..................................................................... 14
Preparing C1DynamicHelp for Authoring Mode ................................................................. 15
For Help Authors: Mapping in Authoring Mode ..................................................................... 16
Mapping a Topic to a Control in Authoring Mode .............................................................. 19
Removing the Topic Mapping for a Selected Control ......................................................... 20
Assign a Topic to a Parent Control ...................................................................................... 20
Advanced Features ................................................................................................................. 21
Displaying any Help Format ................................................................................................ 22
Mapping to Control Parts or Custom Controls ................................................................... 22
DynamicHelp for WinForms Tutorials......................................................................................... 23
Tutorial 1: Mapping Help Topics at Design Time .................................................................... 23
Step 1 of 6: Add controls to the Windows form ................................................................. 24
Step 2 of 6: Set up the C1DynamicHelp control ................................................................. 25
Step 3 of 6: Associate topics with controls on the form ..................................................... 25
Step 4 of 6: Associate a topic with the form ....................................................................... 26
Step 5 of 6: Show topics programmatically ........................................................................ 27
Step 6 of 6: Run the application.......................................................................................... 28
Tutorial 2: Mapping Help Topics in Authoring Mode ............................................................. 29
Step 1 of 4: Add controls to the Windows form ................................................................. 29
Step 2 of 4: Set up the C1DynamicHelp control ................................................................. 30
Step 3 of 4: Using authoring mode ..................................................................................... 33
Step 4 of 4: Run the Application ......................................................................................... 34
API Reference.............................................................................................................................. 35
C1.Win.C1DynamicHelp.4 Assembly ....................................................................................... 35
Namespaces ........................................................................................................................ 35
C1.Win.C1DynamicHelp Namespace .............................................................................. 35

Overview ..................................................................................................................... 35
Classes ......................................................................................................................... 37
C1DynamicHelp ....................................................................................................... 37
Overview ............................................................................................................. 38
Members ............................................................................................................. 39
C1DynamicHelp Constructor ............................................................................... 48
Methods .............................................................................................................. 49
GetHelpTopic Method .................................................................................... 51
SetHelpTopic Method ..................................................................................... 52
ShowDefaultTopic Method ............................................................................. 52
ShowExternalHelp Method ............................................................................. 53
ShowExternalHelp(HelpTab) Method ......................................................... 54
ShowExternalHelp(HelpTab,Object) Method ............................................. 54
ShowTopic Method ......................................................................................... 55
ShowTopic(String) Method ......................................................................... 56
ShowTopic(HelpTopic) Method .................................................................. 57
ShowTopic(Int32) Method .......................................................................... 58
ShowTopic(Object) Method ........................................................................ 59
ShowTopicForActiveControl Method ............................................................. 59
Properties............................................................................................................ 60
AuthoringMode Property................................................................................ 65
BorderStyle Property ...................................................................................... 66
Browser Property ............................................................................................ 66
ContextMenu Property ................................................................................... 67
ContextMenuStrip Property............................................................................ 68
CurrentTopic Property .................................................................................... 68
DefaultTrigger Property .................................................................................. 69
Dock Property ................................................................................................. 69
HelpSource Property ....................................................................................... 70
IsPinnedDown Property .................................................................................. 70
MainControl Property ..................................................................................... 71
MouseHoverDelay Property ........................................................................... 72
Provider Property............................................................................................ 72
Resolver Property ........................................................................................... 73
TopicMap Property ......................................................................................... 74
Events .................................................................................................................. 75

CurrentTopicChanged Event ........................................................................... 76


CurrentTopicChanging Event .......................................................................... 77
Conflict .................................................................................................................... 78
Overview ............................................................................................................. 79
Members ............................................................................................................. 79
Properties............................................................................................................ 80
DynamicItem Property .................................................................................... 81
Name Property ................................................................................................ 81
StaticItem Property ......................................................................................... 82
UIElementPath Property ................................................................................. 82
HelpTopic ................................................................................................................ 83
Overview ............................................................................................................. 83
Members ............................................................................................................. 84
HelpTopic Constructor ........................................................................................ 85
HelpTopic Constructor(String,String,HelpTopicList) ....................................... 86
HelpTopic Constructor(String,String) .............................................................. 87
Methods .............................................................................................................. 88
SetCtxtId Method ............................................................................................ 88
ToString Method ............................................................................................. 89
Properties............................................................................................................ 90
ContextID Property ......................................................................................... 90
SubTopics Property ......................................................................................... 91
Title Property .................................................................................................. 91
Url Property..................................................................................................... 92
HelpTopicList ........................................................................................................... 92
Overview ............................................................................................................. 93
Members ............................................................................................................. 94
HelpTopicList Constructor................................................................................... 96
MapItem.................................................................................................................. 97
Overview ............................................................................................................. 98
Members ............................................................................................................. 99
MapItem Constructor ....................................................................................... 100
Methods ............................................................................................................ 100
ToString Method ........................................................................................... 100
Properties.......................................................................................................... 101
HelpTopic Property ....................................................................................... 102

HelpTopicTrigger Property ............................................................................ 102


ItemType Property ........................................................................................ 103
ShowDefaultTopicFirst Property ................................................................... 104
UIElement Property ...................................................................................... 104
Url Property................................................................................................... 105
UseDefaultTrigger Property .......................................................................... 105
TopicEventArgs ..................................................................................................... 106
Overview ........................................................................................................... 107
Members ........................................................................................................... 108
Properties.......................................................................................................... 108
Cancel Property............................................................................................. 108
Topic Property............................................................................................... 109
TopicMap .............................................................................................................. 109
Overview ........................................................................................................... 111
Members ........................................................................................................... 112
Methods ............................................................................................................ 114
Add Method .................................................................................................. 115
Add(Object,MapItem) Method ................................................................. 116
Add(String,MapItem) Method .................................................................. 117
Contains Method .......................................................................................... 118
Load Method ................................................................................................. 119
Load(String) Method ................................................................................. 120
Load() Method .......................................................................................... 120
Refresh Method ............................................................................................ 121
Remove Method ........................................................................................... 122
Remove(Object) Method .......................................................................... 122
Remove(String) Method ........................................................................... 123
Save Method ................................................................................................. 124
Save() Method........................................................................................... 125
Save(String) Method ................................................................................. 125
Properties.......................................................................................................... 126
Conflicts Property ......................................................................................... 127
HasChanges Property .................................................................................... 128
Item Property ................................................................................................ 128
XmlSource Property ...................................................................................... 129
Events ................................................................................................................ 130

TopicMapChanged Event .............................................................................. 131


TopicMapSaved Event................................................................................... 131
UIElementInfo ....................................................................................................... 132
Overview ........................................................................................................... 132
Members ........................................................................................................... 133
UIElementInfo Constructor ............................................................................... 134
UIElementInfo Constructor(Object) .............................................................. 134
UIElementInfo Constructor(Object,String,Object) ........................................ 135
Properties.......................................................................................................... 137
Name Property .............................................................................................. 137
Parent Property............................................................................................. 138
UIElement Property ...................................................................................... 138
UIElementResolver................................................................................................ 139
Overview ........................................................................................................... 140
Members ........................................................................................................... 141
Methods ............................................................................................................ 141
HandleUIElementEvent Method ................................................................... 141
Enumerations ............................................................................................................ 143
DisplayTarget ........................................................................................................ 143
HelpTab ................................................................................................................. 144
HelpTopicTrigger ................................................................................................... 145
MapItemType ........................................................................................................ 146
UIElementEvents ................................................................................................... 147
Delegates .................................................................................................................. 148
HelpTopicEventHandler ........................................................................................ 148
C1.Win.C1DynamicHelp.Providers Namespace ............................................................ 149
Overview ................................................................................................................... 149
Classes ....................................................................................................................... 149
ChmProvider ......................................................................................................... 149
Overview ........................................................................................................... 150
Members ........................................................................................................... 151
ChmProvider Constructor ................................................................................. 152
Methods ............................................................................................................ 152
CorrectUrl Method........................................................................................ 153
GetCtxtIdMap Method.................................................................................. 154
GetFullUrl Method ........................................................................................ 154

GetTopics Method ........................................................................................ 155


GetUrlMap Method ...................................................................................... 156
ShowExternalHelp Method ........................................................................... 156
ShowExternalHelp(HelpTab) Method ....................................................... 157
ShowExternalHelp(HelpTab,Object) Method ........................................... 157
Properties.......................................................................................................... 158
Source Property ............................................................................................ 159
NetHelpProvider ................................................................................................... 159
Overview ........................................................................................................... 160
Members ........................................................................................................... 161
NetHelpProvider Constructor ........................................................................... 162
Methods ............................................................................................................ 162
CorrectUrl Method........................................................................................ 163
GetCtxtIdMap Method.................................................................................. 164
GetFullUrl Method ........................................................................................ 165
GetTopics Method ........................................................................................ 165
GetUrlMap Method ...................................................................................... 166
ShowExternalHelp Method ........................................................................... 166
ShowExternalHelp(HelpTab) Method ....................................................... 167
ShowExternalHelp(HelpTab,Object) Method ........................................... 168
Properties.......................................................................................................... 168
Source Property ............................................................................................ 169
Interfaces .................................................................................................................. 169
IHelpProvider ........................................................................................................ 169
Overview ........................................................................................................... 170
Members ........................................................................................................... 171
Methods ............................................................................................................ 172
CorrectUrl Method........................................................................................ 173
GetCtxtIdMap Method.................................................................................. 174
GetFullUrl Method ........................................................................................ 174
GetTopics Method ........................................................................................ 175
GetUrlMap Method ...................................................................................... 175
ShowExternalHelp Method ........................................................................... 176
ShowExternalHelp(HelpTab) Method ....................................................... 176
ShowExternalHelp(HelpTab,Object) Method ........................................... 177
Properties.......................................................................................................... 178

Source Property ............................................................................................ 178

DynamicHelp for WinForms Overview


DynamicHelp for WinForms is a container that allows you to view Help files in WinForms
applications. Developers or Help authors can also use DynamicHelp to assign specific Help
topics to controls within an application. The C1DynamicHelp WinForms control displays
context-sensitive help corresponding to the control that is being hovered over or the control
that has the focus. This type of Help system is an advanced feature available in applications
such as Visual Studio, Microsoft Office, Doc-To-Help, and others.
C1DynamicHelp is conceptually similar to using tooltips to provide Help on individual controls
and components. The main difference is that tooltips typically contain only a single sentence or
paragraph. An actual Help topic, by contrast, typically contains more content, often including
hyperlinks, images, tables, and so on. A C1DynamicHelp Help topic also supports selection and
can be copied to the Clipboard.
Topic mapping can be done by software developers or Help authors. The following topics
provide detailed instructions for both groups.

For Developers: Mapping at Design Time


For Help Authors: Mapping in Authoring Mode

See Also
Help with WinForms Edition

Help with WinForms Edition


Getting Started
For information on installing ComponentOne Studio WinForms Edition, licensing, technical
support, namespaces and creating a project with the control, please visit Getting Started with
WinForms Edition.

Key Features

C1DynamicHelp integrates with the application interface


C1DynamicHelp improves the usability of your application by offering immediate and
relevant Help as it is needed, right within the interface of the application. A separate
Help system doesn't need to be opened and searched.

Developers or Help Authors can easily perform topic mapping


Software developers can map topics to controls at design time, or Help Authors can use
authoring mode, a special run-time mode with a simple interface, to do the mapping
themselves. No additional code needs to be added once C1DynamicHelp is integrated
with the application.

Supports Help content selection and copying


The Help that is displayed in the C1DynamicHelp Help window can be selected and
copied to the Clipboard to be pasted into another application.

Quickly activate/deactivate authoring mode


The software developer can specify a way for Help authors to quickly activate and
deactivate authoring mode for topic mapping. Any method can be used, such as a
keystroke combination, an environment variable, a .config file, and so on.

DynamicHelp for WinForms Samples


Please be advised that this ComponentOne software tool is accompanied by various sample
projects and/or demos which may make use of other development tools included with the
ComponentOne Studio.
Please refer to the pre-installed product samples through the following path:

Documents\ComponentOne Samples\WinForms
The following tables provide a short description for each sample.

Visual Basic Samples


Sample

Description

AddingUICommands

This sample shows how to add a toolbar to a C1DynamicHelp


control to provide more functionality:

Allows users to navigate back/forward through help


navigation history.

Allows users to open the Help file in an external window on a


specified tab.

Allows users to pin the current topic down in order to


temporarily disable changing topics.

This sample uses the C1DynamicHelp control.


MultipleForms

This sample demonstrates how to use C1DynamicHelp controls on


multiple forms, how to set them up to use a single help source, and
how to refresh the TopicMap to support controls created dynamically.
This sample uses the C1DynamicHelp control.

UsingUIElementResolver This sample demonstrates how to create a custom UIElementResolver


and use it in the C1DynamicHelp control. This sample uses the
C1DynamicHelp control.
WorkingWithTopicMap

This sample demonstrates how to load topic map from different


locations: from a default topic map file, from a custom file, from
application resources. It also shows how to save a modified topic map
to different locations. This sample uses the C1DynamicHelp control.

C# Samples
Sample

Description

AddingUICommands

This sample shows how to add a toolbar to a C1DynamicHelp


control to provide more functionality:

Allows users to navigate back/forward through help


navigation history.

Allows users to open the Help file in an external window on a


specified tab.

Allows users to pin the current topic down in order to


temporarily disable changing topics.

This sample uses the C1DynamicHelp control.


MultipleForms

This sample demonstrates how to use C1DynamicHelp controls on


multiple forms, how to set them up to use a single help source, and
how to refresh the TopicMap to support controls created dynamically.
This sample uses the C1DynamicHelp control.

UsingUIElementResolver This sample demonstrates how to create a custom UIElementResolver


and use it in the C1DynamicHelp control. This sample uses the
C1DynamicHelp control.
WorkingWithTopicMap

This sample demonstrates how to load topic map from different


locations: from a default topic map file, from a custom file, from
application resources. It also shows how to save a modified topic map
to different locations. This sample uses the C1DynamicHelp control.

10

Using DynamicHelp for WinForms


The process of mapping Help topics to controls within a software application has often been
thought of as an error-prone process of passing a topic map back and forth between Help
authors and software developers. DynamicHelp for WinForms eliminates that painful process
by providing two options:

Software developers can use C1DynamicHelp at design time to map the topics to
controls.
or

Help authors can map topics to controls themselves using the C1DynamicHelp
authoring mode, without having to go through a software developer.

C1DynamicHelp gives you the ability to map a topic to any standard .NET controls and even
parts of those controls. You can also map to custom controls. See the Advanced Features topic
of this documentation for more information on mapping to control parts or custom controls.
DynamicHelp for WinForms supports several Help formats including HTML Help and NetHelp.
No matter who is going to perform the topic mapping, the software developer must specify the
Help file that is going to be used in the application before mapping can occur.
The following topics explain both ways to perform topic mapping.
Note: If you are the software developer of the application and would like the Help author
to map topics to controls, please provide them with this documentation. The For Help
Authors: Mapping in Authoring Mode topic provides all the information needed for topic
mapping at run time in authoring mode.

See Also
For Developers: Mapping at Design Time
For Help Authors: Mapping in Authoring Mode
Advanced Features

For Developers: Mapping at Design Time


C1DynamicHelp provides visual editing at design time to make it easier to map specific Help
topics to controls within an application. You can use the C1DynamicHelp smart tag and Select
Help Topic dialog box to quickly perform topic mapping.

C1DynamicHelp Smart Tag

11

In Visual Studio, the C1DynamicHelp component includes a smart tag. A smart tag ( )
represents a short-cut tasks menu that provides the most commonly used properties for a
control.
To access the C1DynamicHelp Tasks menu, click the smart tag in the upper-right corner of the
C1DynamicHelp control.

HelpSource Property
Click the ellipsis button to locate and select the .chm or NetHelp .htm file that will be
used for topic mapping.
Note:If using NetHelp, use the default.htm or the file name that was used as the base URL
for the NetHelp target.

DefaultTrigger Property
The DefaultTrigger property allows you to specify whether the Help topic will appear
when the control has the focus (Enter), the mouse is hovering over the control
(MouseEnter), or not at all (None).

Select Help Topic Dialog Box


Within this dialog box, you can specify the topic to map to the control through the Table of
Contents tab by simply selecting it, or you can choose the topic's context ID from the Context
IDs tab. Additionally, you can specify here whether a topic should be shown when: the control
gets focus; the mouse hovers over it; both; or neither, in which case, you can show the topic
programmatically.

12

See Also
Specifying the Source Help File
Mapping a Topic to a Control at Design Time
Preparing C1DynamicHelp for Authoring Mode

Specifying the Source Help File


No matter who is going to perform the topic mapping, the software developer must specify the
Help file that is going to be used in the application before mapping can occur. Either NetHelp
or a .chm (compiled HTML Help) can be used by C1DynamicHelp. If using NetHelp, all NetHelp
project files must be deployed with your application. If using HTML Help, only the .chm must be
included.
Any other types of Help files can be used, but this requires some additional programming; you
can use the Provider property and IHelpProvider interface.
Note: In Doc-To-Help, NetHelp project files are stored by default in the NetHelp folder; the
compiled HTML Help file is stored in the HTMLHelp folder.
To specify the source Help file to be used:
1.

From the Toolbox, double-click the C1DynamicHelp control to add it to your form. If
you have not already added the C1DynamicHelp control to the Toolbox, see Adding the
C1DynamicHelp Component to a Project.

13

2.
3.
4.

5.

Click the C1DynamicHelp smart tag ( ) to open the Tasks menu.


Click the ellipsis button next to the HelpSource property.
Locate and select the desired Help file. You can use any *.chm file or NetHelp *.htm file
(use the default.htm or the file name that was used as the base URL for the NetHelp
target).
Click Open.

Mapping a Topic to a Control at Design Time


Once a source Help file is specified, you can easily map topics to controls within your
application through C1DynamicHelp.
1.

2.
3.
4.
5.

From the Toolbox, double-click the C1DynamicHelp control to add it to your form. An
extender property, Help Topic on C1DynamicHelp, is added to all controls when
C1DynamicHelp is added to the form.
Click the C1DynamicHelp smart tag ( ) to open the Tasks menu.
Click the ellipsis button next to the HelpSource property.
Locate and select the desired Help file, and click Open.
Select one of the controls on your form and click the ellipsis button next to the
HelpTopic on C1DynamicHelp property in the Properties window. The Select Help
Topic dialog box appears and shows the Table of Contents tab and TOC from the
specified Help file.

By default, the Use default events check box is selected (the selected options will vary
by the control youve chosen to map to). Got focus sets the Help topic to display when
the control has been selected; Mouse hover sets the Help topic to display when the
control has been hovered over. To change the default options, clear the Use default
events check box and select either the Got focus or Mouse hover check box.

14

o
o

If mapping to the TOC: From the Select Help Topic dialog box, Table of
Contents tab, choose a topic.
If mapping to the context ID list: From the Select Help Topic dialog box,
Context ID tab, choose the context ID/Topic pairing.
Note: In order to map to a topic, the topic must be in the Help TOC or have a context ID
assigned to it; otherwise, it will not appear in the Select Help Topic dialog box. Also, if the
Help author renames one of the TOC items, the mapping will break. You must get the
updated Help and re-create the mapping with the updated TOC.

6.

Click OK to close the Select Help Topic dialog box. The topic is mapped to the control
and appears in the C1DynamicHelp Help window at run time when a user clicks or
mouses over the control.

Preparing C1DynamicHelp for Authoring


Mode
To allow Help authors to activate and deactivate C1DynamicHelp authoring mode so that they
can map topics in your application, you have a wide variety of options. You can use anything
from a special keystroke combination to a registry node that, if present, activates authoring
mode.
This example shows how to specify a keystroke combination.
1.
2.

Specify a source Help file for C1DynamicHelp.


Select your Form and set the KeyPreview property to True in the Properties window.

15

3.
4.

Select View | Code so you can add code to override the OnKeyDown method and
specify a keystroke combination to activate and deactivate authoring mode.
Add the following code:
To write code in Visual Basic
Visual Basic

Copy Code

' toggle authoring mode when the user hits Ctrl+Shift+A


Protected Overrides Sub OnKeyDown(ByVal e As
System.Windows.Forms.KeyEventArgs)
If (e.KeyCode = Keys.A And e.Control And e.Shift) Then
C1DynamicHelp1.AuthoringMode = Not C1DynamicHelp1.AuthoringMode
End If
MyBase.OnKeyDown(e)
End Sub
To write code in C#
C#

Copy Code

// toggle authoring mode when the user hits Ctrl+Shift+A


override protected void OnKeyDown(KeyEventArgs e)
{
if (e.KeyCode == Keys.A && e.Control && e.Shift)
{
c1DynamicHelp1.AuthoringMode = !c1DynamicHelp1.AuthoringMode;
}
base.OnKeyDown(e);
}
C1DynamicHelp authoring mode will be activated or deactivated when the user presses the
Ctrl+Shift+A keys.

For Help Authors: Mapping in Authoring


Mode
Topic mapping is generally performed by the application Help author or Information Developer;
for that reason, the roles of the Information Developer and Software Developer in the process
are clearly defined here, although one person may perform both roles.
The files used for mapping include:

16

NetHelp project files or .chm (compiled HTML Help)


The Help file format is specified by the software developer. If using NetHelp, all of the
files in the output folder of your Help project must be deployed with the application. If
using HTML Help, only the .chm must be included.
Note: In Doc-To-Help, NetHelp project files are stored by default in the NetHelp folder; the
compiled HTML Help file is stored in the HTMLHelp folder.

Default.htm.xml or HelpFileName.chm.xml
When you create mappings, they are saved to the default.htm.xml or
HelpFileName.chm.xml located in the same directory as your source Help file, by
default. This XML is used to show the topics when the application runs.

You cannot begin mapping until you place your Help into the correct folder. NetHelp or .chm
files should be copied to the install folder specified by the software developer for your
application (for example: \\program files\componentone\DocToHelp\Help).
When you have finished mapping topics, the .chm or NetHelp project files and the .xml
containing the topic mappings must be given to the software developer.
Note: The .xml mapping file should never be edited manually. If mappings need to be
deleted, use the C1DynamicHelp authoring mode (see below).

C1DynamicHelp Authoring Mode


DynamicHelp for WinForms provides a special run-time mode, authoring mode, for Help
authors to use for assigning topics to controls within an application. When activated, the
authoring mode panel and toolbar appear.

17

Information about the control being mapped to is provided in the Selected control area of the
panel, which is made up of the following fields:
Control Control name : type of control.
Path

The path of the control relative to its placement on the form. For example, a Node
within a TreeView control may have a path that looks like this:
Form1\TreeView1\Node0.

Type

Type of control.

Topic

Topic to associate with the control.

The software developer controls how you to activate and deactivate authoring mode.

See Also
Mapping a Topic to a Control in Authoring Mode
Removing the Topic Mapping for a Selected Control
Assign a Topic to a Parent Control

18

Mapping a Topic to a Control in Authoring


Mode
To map a control to a topic using the C1DynamicHelp authoring mode, use the following
steps:
1.

2.

Display the area of the application's interface that you would like to map. For example,
if you are going to map ribbons, make sure they are all available. If you are going to
map windows, make sure they are all open.
Activate authoring mode using the method specified by the software developer. The
authoring mode panel appears.

3.
4.

Click the Select control button


.
Click the item you would like to map a Help topic to. As you move the mouse over the
controls, you will see information about them in the authoring mode panel: Control
name, Path, control Type, and associated Topic, if applicable.

5.

Click the Attach topic to control button


. The Select Help Topic dialog box
appears and shows the Table of Contents tab and TOC from the source Help file.

By default, the Use default events check box is selected (the selected options will vary
by the control youve chosen to map to). Got focus sets the Help topic to display when
the control has been selected; Mouse hover sets the Help topic to display when the
control has been hovered over. To change the default options, clear the Use default
events check box and select either the Got focus or Mouse hover check box.

19

If mapping to the TOC: From the Select Help Topic dialog box, Table of
Contents tab, choose a topic. Click OK. The topic chosen will display in the
Topic field of the authoring mode panel.
If mapping to the context ID list: From the Select Help Topic dialog box,
Context ID tab, choose the context ID/Topic pairing. Click OK. The topic
chosen will display in the Topic field of the authoring mode panel.
Note: In order to map to a topic, the topic must be in the Help TOC or have a context ID
assigned to it; otherwise, it will not appear in the Select Help Topic dialog box. Also, if you
rename one of the TOC items, the mapping will break. Simply drop the updated Help into
the proper folder and re-create the mapping with the updated TOC.

6.
7.
8.
9.

Click the Save button


.
Continue mapping.
To close the window, use the method specified by the software developer.
Deliver the .xml mapping file to the software developer.
Note: After mapping, you should backup the .xml mapping file elsewhere on your
machine. If you uninstall or reinstall your software product, the .xml mapping file will be
deleted and replaced.

Removing the Topic Mapping for a Selected


Control
To remove the topic mapping for a selected control, use the following steps:
1.

Activate authoring mode using the method specified by the software developer. The
authoring mode panel appears.

2.

Click the Select Control button


and select the control that you would like to
remove the topic mapping from. The control name appears in the Control field of the
authoring mode panel, so you can make sure the correct control has been selected.

3.

Click the Detach Topic from Control button


. The topic mapping is removed.
Notice there is no longer a topic specified in the Topic field.

4.
5.

Click the Save button


.
Close the mapping window and deliver the proper Help and .xml mapping file to the
software developer.

Assign a Topic to a Parent Control


There may be times you need to attach a topic not to a control you can select, but to its parent
or ancestor. Since the parent can be completely covered by child controls and thus
unselectable, there is a special provision to do it in authoring mode.

20

1.

Activate authoring mode using the method specified by the software developer. The
authoring mode panel appears.

2.
3.

Click the Select control button


.
Click the child control of the parent or ancestor control you would like to map a Help
topic to.
Click the drop-down arrow in the Control combo box and select the parent or ancestor
to map to.

4.

5.
6.
7.
8.

Click the Attach topic to control button


. The Select Help Topic dialog box
appears and shows the Table of Contents tab and TOC from the source Help file.
Select the topic from the Table of Contents tab or select the context ID/Topic pairing
on the Context IDs tab, and specify any desired events.
Click the Save button
.
Close the mapping window and deliver the proper Help and .xml mapping file to the
software developer.

Advanced Features
DynamicHelp for WinForms requires almost no programming to be used in most cases, but
sometimes you may want to use the best of it. The following advanced features are described in
this topic:

Displaying any Help format


C1DynamicHelp allows you to use different help formats. This topic describes two builtin help providers, ChmProvider and NetHelpProvider, and how to implement your own
help provider to display a help file in the format you want.

Mapping to part of a control or custom controls


C1DynamicHelp gives you the ability to map a topic not only to standard controls but
also to parts of controls or to custom controls. C1DynamicHelp provides this feature for
standard .Net controls derived from the System.Windows.Forms.Control class. But if you
want to extend it to your needs, you can create your own UI element resolver class.

See Also
Displaying any Help Format
Mapping to Control Parts or Custom Controls

21

Displaying any Help Format


You may want to use different help formats in your application:

HTML help;
NetHelp;
MS Help 2.0;
WinHelp;
RoboHelp WebHelp;
and so on.

C1DynamicHelp provides means for displaying these or any other help formats.
HTML Help and NetHelp formats can be displayed by the C1DynamicHelp control without any
additional programming. There are two built-in help providers in C1DynamicHelp, ChmProvider
and NetHelpProvider, which are used automatically when the HelpSource property points to a
.chm or an .htm/html file, correspondingly.
Any other types of help files can be used, but this requires some additional programming. In
this case you will have to create your own help provider class that implements the IHelpProvider
interface. This interface provides all necessary information about a help format to the
C1DynamicHelp control. So any help provider can read data from a help source and provides
methods to get help topics, to get context IDs, to open help in an external window, to get a
topic URL that can be displayed by the C1DynamicHelp control, and so on. After creating your
own help provider, all you need is to set it to the Provider property.
For more details see:

the IHelpProvider interface, which must be implemented by every help provider;


the Provider property;
the NetHelpProvider sample, which is the full code actually used in the C1DynamicHelp
control.

Mapping to Control Parts or Custom Controls


Mapping to Control Parts or Custom Controls
C1DynamicHelp allows you to map a help topic to any control derived from the
System.Windows.Forms.Control class. In most cases it will be enough, but sometimes you may
want to map a topic not to a control itself but to some part of it or map a topic to a custom
control which is not derived from the System.Windows.Forms.Control. We will refer to these
parts of controls and the custom controls as UI elements. To inform the C1DynamicHelp control
how to handle UI elements, you will need to create your own class derived from the
UIElementResolver class and set it as the Resolver property.
You will need to create a class derived from the UIElementResolver only if you are using custom
controls that cannot be handled by the C1DynamicHelp control automatically and then only if
you need to associate help topics with parts (UI elements) of those controls, not with the
controls themselves.

22

You have no need to create objects of UIElementResolver type, it is sufficient to define a class
derived from UIElementResolver and override its virtual methods. These overridden methods
must provide necessary information about UI elements inside custom controls used in your
application: methods to find UI elements inside a control by name, coordinates, etc., and other
methods necessary for associating dynamic help to UI elements inside a control.
C1DynamicHelp automatically handles most popular, standard controls. For example, it allows
mapping a topic to all standard .Net controls and to their parts. So, for example, you can
associate a help topic to a separate node of the standard TreeView control or to a separate
ListViewItem of the ListView control; that you can do without creating your own
UIElementResolver class.
For more details see:

the UIElementResolver class, from which you derive your own UI element resolver class;
the Resolver property;
the UsingUIElementResolver sample, which shows how to create custom UI element
resolver for the C1Ribbon control to allow mapping topics to items inside C1Ribbon
such as tabs, buttons, groups, etc.

DynamicHelp for WinForms Tutorials


The following tutorials provide step-by-step instructions on mapping Help topics to controls
within an application. Tutorial 1 explains how to map Help topics at design time within Visual
Studio. This is usually done by a software developer. Tutorial 2 explains how software
developers can set up C1DynamicHelp authoring mode and how Help authors can then use it
to assign topics to controls on a form, without having to manually edit a topic map.

See Also
Tutorial 1: Mapping Help Topics at Design Time
Tutorial 2: Mapping Help Topics in Authoring Mode

Tutorial 1: Mapping Help Topics at Design


Time
This tutorial explains how to use C1DynamicHelp to map Help topics to controls on a form at
design time within Visual Studio. This is usually done by a software developer.

See Also
Step 1 of 6: Add controls to the Windows form
Step 2 of 6: Set up the C1DynamicHelp control
Step 3 of 6: Associate topics with controls on the form
Step 4 of 6: Associate a topic with the form

23

Step 5 of 6: Show topics programmatically


Step 6 of 6: Run the application

Step 1 of 6: Add controls to the Windows


form
In this step, you will add the C1DynamicHelp control to your form, along with a TextBox,
Button, and Checkbox.
1.

2.
3.

4.

5.

Create a .NET project and add the C1DynamicHelp control to the Toolbox. An extender
property, Help Topic on C1DynamicHelp, is added to all controls when
C1DynamicHelp is added to the form.
From the Toolbox, double-click the C1DynamicHelp control. It docks at the right of your
form.
Add a TextBox control to the form:
1. From the Toolbox, double-click the TextBox control to add it to your form.
2. From the Properties window, set the textBox1.Text property to Show topic on
got focus.
Add a Button control to the form:
1. From the Toolbox, double-click the Button control to add it to your form.
2. From the Properties window, set the button1.Text property to Show topic on
mouse hover.
Add a CheckBox control to the form:
1. From the Toolbox, double-click the CheckBox control to add it to your form.
2. From the Properties window, set the checkBox1.Text property to Show topic
programmatically.

You have successfully added the controls to your form, which should look similar to the
following:

In the next step you will set up the C1DynamicHelp control.

24

Step 2 of 6: Set up the C1DynamicHelp


control
In order to associate topics from your Help file with form controls, you must specify the source
Help file.
You can do this from the C1DynamicHelp Tasks menu by setting the HelpSource property to
any *.chm file or NetHelp *.htm file (use the default.htm or the file name that was used as the
base URL for the NetHelp target.). In this example, we will use the C1Sample.chm installed with
DynamicHelp for WinForms, by default.
1.
2.
3.
4.

Click the C1DynamicHelp smart tag ( ) to open the Tasks menu.


Click the ellipsis button next to the HelpSource property.
Locate and select the C1Sample.chm. It is located in the Tutorials/Data folder, by
default.
Click Open.

Step 3 of 6: Associate topics with controls on


the form
You can associate Help topics with controls using the Select Help Topic dialog box.
1.

Select Button1 and click the ellipsis button next to the HelpTopic on
C1DynamicHelp1 property in the Properties window. The Select Help Topic dialog
box opens:

25

2.
3.
4.

Select any help topic from the Table of Contents tab and click OK. In this example, we
will select the Overview topic.
Select TextBox1 and set its HelpTopic on C1DynamicHelp1 property to any topic
from the Table of Contents tab.
In the Events group of the Select Help Topic dialog box, uncheck Use default events
and check the Got focus checkbox next to Show on events.

Unchecking Use default events allows you to specify the events on a per-control basis.
Otherwise, the DefaultTrigger property is used for all controls. Using the Events
settings makes showing topics automatic when a control obtains focus or the mouse
hovers over it, or in both cases. But if you want manual control over what triggers topic
display, you can uncheck both check boxes (or set DefaultTrigger=None; this will do it
for all controls if it's not overridden on a per-control basis) and show topics
programmatically.
5.

Click OK.

Step 4 of 6: Associate a topic with the form


You can also use the Select Help Topic dialog box to associate a topic with your form.
1.

Select Form1 and click the ellipsis button next to the HelpTopic on C1DynamicHelp1
property in the Properties window. The Select Help Topic dialog box appears, but
notice the Events group is different; in this case, it has one check box Always show
default topic first on form open.
The topic associated with the form is the default topic. It is shown when the control that
displays the current topic due to a focus/mouse hover event loses focus/mouse hover.

26

If the check box Always show default topic first on form open is checked, the default
topic is also shown when the form is opened.

2.

Select the default topic from the Table of Contents tab.

Step 5 of 6: Show topics programmatically


You can show a specific topic programmatically by using the ShowTopic method.
Create a CheckedChanged event handler for CheckBox1 and add code so it looks like the
following:
To write code in Visual Basic
Visual Basic

Copy Code

Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e


As System.EventArgs) Handles CheckBox1.CheckedChanged
C1DynamicHelp1.ShowTopic("WordDocuments/glossaryofterms.htm")
End Sub
To write code in C#

27

C#

Copy Code

private void checkBox1_CheckedChanged(object sender, System.EventArgs e)


{
c1DynamicHelp1.ShowTopic("WordDocuments/glossaryofterms.htm");
}

Step 6 of 6: Run the application


To run the application, click the Start Debugging button and notice the following results:

When Form1 is loaded, the default topic is shown.


When the mouse is over the button, the topic is displayed.
Check or uncheck Show topic programmatically to display its associated topic.
When TextBox1 gets the focus, it displays the specified topic.

Congratulations, you have successfully completed Tutorial 1! In this tutorial you have learned
how to:

Add and set up the C1DynamicHelp control.


Associate topics with controls on a form at design-time.
Show topics programmatically.

28

Tutorial 2: Mapping Help Topics in


Authoring Mode
This tutorial shows the second method of assigning Help topics to controls on a form. It is done
entirely by Help authors; once a software developer sets up his application to use the
C1DynamicHelp authoring mode, he doesn't need to do anything to map topics to controls!
This eliminates the error-prone process of passing the topic/control map back and forth
between Help authors and software developers.
The first two steps of this tutorial explain how software developers can set up their applications
for authoring mode. Step 3 explains how Help authors can assign topics to controls in
authoring mode. The final step shows how the Help appears in the application.

See Also
Step 1 of 4: Add controls to the Windows form
Step 2 of 4: Set up the C1DynamicHelp control
Step 3 of 4: Using authoring mode
Step 4 of 4: Run the Application

Step 1 of 4: Add controls to the Windows


form
To set up your new Form with the C1DynamicHelp control, a TextBox, and a TreeView control,
complete the following steps. These steps should be performed by the software developer.
1.
2.
3.

4.

Create a .NET project and add the C1DynamicHelp control to the Toolbox.
From the Toolbox, double-click the C1DynamicHelp control. It docks at the right of your
form.
Add a TextBox control to the form:
1. From the Toolbox, double-click the TextBox control to add it to your form.
2. From the Properties window, set the textBox1.Text property to Show topic on
got focus.
Add the TreeView control to the form:
1. From the Toolbox, double-click the TreeView control to add it to your form.
2. From the Properties window, add nodes to the treeView1 according to the
following image:

29

In the next step you will set up the C1DynamicHelp control.

Step 2 of 4: Set up the C1DynamicHelp


control
In order to associate topics from your Help file with form controls, you must specify the source
Help file.
You can do this from the C1DynamicHelp Tasks menu by setting the HelpSource property to
any *.chm file or NetHelp *.htm file (use the default.htm or the file name that was used as the
base URL for the NetHelp target.). In this example, we will use the C1Sample.chm installed with
DynamicHelp for WinForms, by default.
Once a source Help file is specified, you can prepare the C1DynamicHelp control to be used in
authoring mode. This step should be performed by the developer.
1.
2.
3.
4.

Click the C1DynamicHelp smart tag ( ) to open the Tasks menu.


Click the ellipsis button next to the HelpSource property.
Locate and select the C1Sample.chm. It is located in the Tutorials/Data folder, by
default.
Prepare the C1DynamicHelp control for using in authoring mode:
1. From the Properties window, set the Form1.KeyPreview property to True.
2. Override the OnKeyDown method by adding the following code:
To write code in Visual Basic
Visual Basic

Copy Code

' toggle authoring mode when the user hits Ctrl+Shift+A

30

Protected Overrides Sub OnKeyDown(ByVal e As


System.Windows.Forms.KeyEventArgs)
If (e.KeyCode = Keys.A And e.Control And e.Shift) Then
C1DynamicHelp1.AuthoringMode = Not C1DynamicHelp1.AuthoringMode
End If
MyBase.OnKeyDown(e)
End Sub
To write code in C#
C#

Copy Code

// toggle authoring mode when the user hits Ctrl+Shift+A


override protected void OnKeyDown(KeyEventArgs e)
{
if (e.KeyCode == Keys.A && e.Control && e.Shift)
{
c1DynamicHelp1.AuthoringMode = !c1DynamicHelp1.AuthoringMode;
}
base.OnKeyDown(e);
}
3.

Create a handler for the Form_Load event and insert the following code to
instruct the C1DynamicHelp control to subscribe the controls to the events for
showing topics:
To write code in Visual Basic
Visual Basic

Copy Code

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles MyBase.Load
C1DynamicHelp1.TopicMap.Refresh()
End Sub
To write code in C#
C#

Copy Code

31

private void Form1_Load(object sender, EventArgs e)


{
c1DynamicHelp1.TopicMap.Refresh();
}
5.

Create a handler for the Form_Closing event and insert the following code to ask the
user whether to save changes made in the topic map:
To write code in Visual Basic
Visual Basic

Copy Code

Private Sub Form1_FormClosing(ByVal sender As System.Object, ByVal e As


System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
If (C1DynamicHelp1.TopicMap.HasChanges) Then
Dim dr As DialogResult
dr = MessageBox.Show("Would you like to save the changes you made to
control/topic map?", "C1DynamicHelp Tutorial", MessageBoxButtons.YesNoCancel,
MessageBoxIcon.Question)
If (dr = DialogResult.Yes) Then
C1DynamicHelp1.TopicMap.Save()
ElseIf (dr = DialogResult.Cancel) Then
e.Cancel = True
End If
End If
End Sub
To write code in C#
C#

Copy Code

private void Form1_FormClosing(object sender, FormClosingEventArgs e)


{
if (c1DynamicHelp1.TopicMap.HasChanges)
{
DialogResult result = MessageBox.Show("Would you like to save the
changes you made to control/topic map?", "C1DynamicHelp Tutorial",
MessageBoxButtons.YesNoCancel , MessageBoxIcon.Question);
if (result == DialogResult.Yes)
c1DynamicHelp1.TopicMap.Save();

32

else if (result == DialogResult.Cancel)


e.Cancel = true;
}
}
No controls have topics associated with them yet. The application can now be used by a Help
author to map topics to controls.

Step 3 of 4: Using authoring mode


This step explains how the Help author can activate authoring mode and associate topics with
controls.
1.

Run the application from the software developer and press the Ctrl+Shift+A keys
together to activate authoring mode. The authoring mode panel appears.

2.

Map a topic to the TextBox control:


1.

Click Select control button

and select TextBox1.

2.

3.

Click the Attach topic to control button


. The Select Help Topic dialog
box appears.
3. On the Table of Contents tab, select the Glossary of Terms topic.
4. Uncheck the Use default events and Mouse hover checkboxes so that only
Got focus is checked.
5. Click OK. Note that a topic is now displayed only when TextBox1 gets focus not when the mouse hovers over it.
Map a topic to the TreeView nodes:
1.

Click Select control button

2.

Click the Attach topic to control button


. The Select Help Topic dialog
box appears.
On the Table of Contents tab, select the Overview topic and click OK.
Assign the How to use C1DynamicHelp topic to the How to Use node using
steps a-c.
Assign the Design time support topic to the Design time node using steps a-c.
Assign the Runtime support topic to the Runtime node using steps a-c. Note
that the corresponding topics are displayed when the mouse hovers over each
of the TreeView nodes.

3.
4.
5.
6.

and select the Overview node.

Note: In authoring mode you have the ability to associate topics with objects whose class
is not derived from Component, such as TreeNode or ListBox items. This cannot be done
at design time, because there is no Component to set for the HelpTopic on

33

C1DynamicHelp1 property.

4.

Click the Save control/topic mapping


that serves as the topic map.

button to save the changes to an .xml file

Note: If you close the application without saving the control/topic mapping, a dialog box
will appear, prompting you to save the changes.

5.

6.
7.

8.

The topic map is saved to the same location as the Help file specified in the HelpSource
property. It will also have the same name as the specified Help file, only with an .xml
extension. In this example, the topic map can be found in the C1Sample.chm.xml file.
It should now look like this:
XML code
<Dictionary>
<item>
<key>Form1\textBox1</key>
<value>WordDocuments/glossaryofterms.htm</value>
<events useDefaultEvents="False">1</events>
</item>
<item>
<key>Form1\treeView1\Node1</key>
<value>WordDocuments/howtousec1dynamichelp.htm</value>
<events useDefaultEvents="True">3</events>
</item>
<item>
<key>Form1\treeView1\Node0</key>
<value>WordDocuments/overview.htm</value>
<events useDefaultEvents="True">3</events>
</item>
<item>
<key>Form1\treeView1\Node1\Node2</key>
<value>WordDocuments/designtimesupport.htm</value>
<events useDefaultEvents="True">3</events>
</item>
<item>
<key>Form1\treeView1\Node1\Node3</key>
<value>WordDocuments/runtimesupport.htm</value>
<events useDefaultEvents="True">3</events>
</item>
</Dictionary>
Give the C1Sample.chm.xml file, along with the updated Help file(s), if changed, to the
software developer.

Step 4 of 4: Run the Application


To run the application, click the Start Debugging button and notice the following results. This
step should be performed by the developer.

34

When the mouse hovers over the TreeView nodes, the specified topics are displayed.
Only when TextBox1 gets the focus will it display a topic.

Congratulations, you have successfully completed Tutorial 2! In this tutorial you have learned
how to:

Add and set up the C1DynamicHelp control.


Activate/deactivate authoring mode.
Associate topics to controls on a form in authoring mode.
Save changes in the topic map.

API Reference
The following topics contain the API reference for DynamicHelp for WinForms.

See Also
C1.Win.C1DynamicHelp.4 Assembly

C1.Win.C1DynamicHelp.4 Assembly
Namespaces
C1.Win.C1DynamicHelp Namespace
Overview
Classes

35

Class

Description

C1DynamicHelp

Provides dynamic help for applications.

Conflict

Class used in the TopicMap.Conflicts property of the TopicMap.

HelpTopic

Represents a topic in a help file.

HelpTopicList

List of HelpTopic objects.

MapItem

Class containing a pair consisting of a topic and a user action


triggering its display.

TopicEventArgs

Provides data for a topic change event.

TopicMap

Class used to store combinations of topics and user actions that cause
their display.

UIElementInfo

This class contains information about a UI element: its Name and


Parent.

UIElementResolver This class provides methods to find UI elements inside a control by


name, coordinates, etc, and other methods necessary for associating
dynamic help to UI elements inside a control.

Delegates
Delegate

Description

HelpTopicEventHandler Represents a method that will handle the


C1DynamicHelp.CurrentTopicChanging event of a
C1DynamicHelp.

Enumerations
Enumeration

Description

DisplayTarget

Enumeration that specifies where a topic will be displayed.

36

HelpTab

Enumeration specifying the part/element of the help file to display.

HelpTopicTrigger Enumeration that specifies user actions that cause a HelpTopic to be


displayed.
MapItemType

Enumeration that specifies topic map item type.

UIElementEvents

Enumeration that specifies which of the monitored events occurred for


a UI element.

See Also
Reference
C1.Win.C1DynamicHelp.4 Assembly

Classes
C1DynamicHelp
Provides dynamic help for applications.

Object Model

Syntax
Visual Basic (Declaration)
Public Class C1DynamicHelp
Inherits System.Windows.Forms.Control
C#
public class C1DynamicHelp : System.Windows.Forms.Control

Remarks
The C1DynamicHelp control displays help topics from CHM, NetHelp and other help files.
The HelpSource property specifies the help file containing the documentation.
Topics in the help file can be associated with components in the application either by a
programmer at design time, using the HelpTopic extender property, or without programmers,
using the control's 'authoring mode' facilities.

37

Inheritance Hierarchy
System.Object
System.MarshalByRefObject
System.ComponentModel.Component
System.Windows.Forms.Control
C1.Win.C1DynamicHelp.C1DynamicHelp

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Members
C1.Win.C1DynamicHelp Namespace

Overview
Provides dynamic help for applications.

Object Model

Syntax
Visual Basic (Declaration)
Public Class C1DynamicHelp
Inherits System.Windows.Forms.Control
C#
public class C1DynamicHelp : System.Windows.Forms.Control

Remarks
The C1DynamicHelp control displays help topics from CHM, NetHelp and other help files.
The HelpSource property specifies the help file containing the documentation.
Topics in the help file can be associated with components in the application either by a
programmer at design time, using the HelpTopic extender property, or without programmers,
using the control's 'authoring mode' facilities.

Inheritance Hierarchy
38

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
System.Windows.Forms.Control
C1.Win.C1DynamicHelp.C1DynamicHelp

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Members
C1.Win.C1DynamicHelp Namespace

Members
Properties Methods Events

The following tables list the members exposed by C1DynamicHelp.

Public Constructors
Name

Description

C1DynamicHelp Constructor Creates a new instance of the C1DynamicHelp control.


Top

Public Properties
Name

Description

AccessibilityObject

(Inherited from System.Windows.Forms.Control)

AccessibleDefaultActionDescription (Inherited from System.Windows.Forms.Control)


AccessibleDescription

(Inherited from System.Windows.Forms.Control)

AccessibleName

(Inherited from System.Windows.Forms.Control)

AccessibleRole

(Inherited from System.Windows.Forms.Control)

39

Anchor

(Inherited from System.Windows.Forms.Control)

AuthoringMode

Gets or sets a value indicating whether the control is


currently in 'authoring mode'.

AutoScrollOffset

(Inherited from System.Windows.Forms.Control)

BindingContext

(Inherited from System.Windows.Forms.Control)

BorderStyle

Gets or sets the type of border to display around the


control.

Bottom

(Inherited from System.Windows.Forms.Control)

Bounds

(Inherited from System.Windows.Forms.Control)

Browser

Provides access to the browser object used to display


the topics, so the programmer can use browser
features programmatically, for example, to navigate
help topics inside the C1DynamicHelp control.

CanFocus

(Inherited from System.Windows.Forms.Control)

CanSelect

(Inherited from System.Windows.Forms.Control)

Capture

(Inherited from System.Windows.Forms.Control)

CausesValidation

(Inherited from System.Windows.Forms.Control)

ClientRectangle

(Inherited from System.Windows.Forms.Control)

ClientSize

(Inherited from System.Windows.Forms.Control)

CompanyName

(Inherited from System.Windows.Forms.Control)

Container

(Inherited from
System.ComponentModel.Component)

40

ContainsFocus

(Inherited from System.Windows.Forms.Control)

ContextMenu

Overridden. Gets or sets the shortcut menu


associated with the control.

ContextMenuStrip

Overridden. Gets or sets the


System.Windows.Forms.ContextMenuStrip associated
with this control.

Controls

(Inherited from System.Windows.Forms.Control)

Created

(Inherited from System.Windows.Forms.Control)

CurrentTopic

Gets or sets the HelpTopic that is currently displayed


by the C1DynamicHelp control.

DataBindings

(Inherited from System.Windows.Forms.Control)

DefaultTrigger

Gets or sets a default HelpTopicTrigger value for the


C1DynamicHelp control.

DisplayRectangle

(Inherited from System.Windows.Forms.Control)

Disposing

(Inherited from System.Windows.Forms.Control)

Dock

Overridden. Gets or sets which control borders are


docked to its parent control and determines how the
control is resized with its parent.

Focused

(Inherited from System.Windows.Forms.Control)

Handle

(Inherited from System.Windows.Forms.Control)

HasChildren

(Inherited from System.Windows.Forms.Control)

Height

(Inherited from System.Windows.Forms.Control)

HelpSource

Gets or sets the location of the help source, such as

41

the name of a .chm file (for HTML Help) or the name


of the main .htm file (for NetHelp).
InvokeRequired

(Inherited from System.Windows.Forms.Control)

IsAccessible

(Inherited from System.Windows.Forms.Control)

IsDisposed

(Inherited from System.Windows.Forms.Control)

IsHandleCreated

(Inherited from System.Windows.Forms.Control)

IsMirrored

(Inherited from System.Windows.Forms.Control)

IsPinnedDown

Gets or sets a value indicating whether the current


help topic is pinned down.

LayoutEngine

(Inherited from System.Windows.Forms.Control)

Left

(Inherited from System.Windows.Forms.Control)

Location

(Inherited from System.Windows.Forms.Control)

MainControl

Gets or sets a reference to another C1DynamicHelp


control which will be used as a source of data for the
current C1DynamicHelp control.

Margin

(Inherited from System.Windows.Forms.Control)

MaximumSize

(Inherited from System.Windows.Forms.Control)

MinimumSize

(Inherited from System.Windows.Forms.Control)

MouseHoverDelay

Gets or sets the interval, in milliseconds, between the


time the mouse enters a control or component and
the time the associated HelpTopic is displayed in the
C1DynamicHelp control.

Name

(Inherited from System.Windows.Forms.Control)

42

Parent

(Inherited from System.Windows.Forms.Control)

PreferredSize

(Inherited from System.Windows.Forms.Control)

ProductName

(Inherited from System.Windows.Forms.Control)

ProductVersion

(Inherited from System.Windows.Forms.Control)

Provider

Gets or sets a reference to a help provider.

RecreatingHandle

(Inherited from System.Windows.Forms.Control)

Region

(Inherited from System.Windows.Forms.Control)

Resolver

Represents a class with virtual methods that are used


to supply information about custom controls used in
the application.

Right

(Inherited from System.Windows.Forms.Control)

Site

(Inherited from System.Windows.Forms.Control)

Size

(Inherited from System.Windows.Forms.Control)

TabIndex

(Inherited from System.Windows.Forms.Control)

TabStop

(Inherited from System.Windows.Forms.Control)

Tag

(Inherited from System.Windows.Forms.Control)

Top

(Inherited from System.Windows.Forms.Control)

TopicMap

A dictionary that maps UI elements to MapItem


objects.

TopLevelControl

(Inherited from System.Windows.Forms.Control)

Visible

(Inherited from System.Windows.Forms.Control)

43

Width

(Inherited from System.Windows.Forms.Control)

Top

Public Methods
Name

Description

BeginInvoke

Overloaded. (Inherited from System.Windows.Forms.Control)

BringToFront

(Inherited from System.Windows.Forms.Control)

Contains

(Inherited from System.Windows.Forms.Control)

CreateControl

(Inherited from System.Windows.Forms.Control)

CreateGraphics

(Inherited from System.Windows.Forms.Control)

CreateObjRef

(Inherited from System.MarshalByRefObject)

Dispose()

(Inherited from System.ComponentModel.Component)

DoDragDrop

(Inherited from System.Windows.Forms.Control)

DrawToBitmap

(Inherited from System.Windows.Forms.Control)

EndInvoke

(Inherited from System.Windows.Forms.Control)

FindForm

(Inherited from System.Windows.Forms.Control)

Focus

(Inherited from System.Windows.Forms.Control)

GetChildAtPoint

Overloaded. (Inherited from System.Windows.Forms.Control)

GetContainerControl

(Inherited from System.Windows.Forms.Control)

GetHelpTopic

Gets the MapItem object currently associated with a given UI


element.

44

GetLifetimeService

(Inherited from System.MarshalByRefObject)

GetNextControl

(Inherited from System.Windows.Forms.Control)

GetPreferredSize

(Inherited from System.Windows.Forms.Control)

Hide

(Inherited from System.Windows.Forms.Control)

InitializeLifetimeService

(Inherited from System.MarshalByRefObject)

Invalidate

Overloaded. (Inherited from System.Windows.Forms.Control)

Invoke

Overloaded. (Inherited from System.Windows.Forms.Control)

PerformLayout

Overloaded. (Inherited from System.Windows.Forms.Control)

PointToClient

(Inherited from System.Windows.Forms.Control)

PointToScreen

(Inherited from System.Windows.Forms.Control)

PreProcessControlMessage

(Inherited from System.Windows.Forms.Control)

PreProcessMessage

(Inherited from System.Windows.Forms.Control)

RectangleToClient

(Inherited from System.Windows.Forms.Control)

RectangleToScreen

(Inherited from System.Windows.Forms.Control)

Refresh

(Inherited from System.Windows.Forms.Control)

ResetText

(Inherited from System.Windows.Forms.Control)

ResumeLayout

Overloaded. (Inherited from System.Windows.Forms.Control)

Scale

(Inherited from System.Windows.Forms.Control)

Select

(Inherited from System.Windows.Forms.Control)

45

SelectNextControl

(Inherited from System.Windows.Forms.Control)

SendToBack

(Inherited from System.Windows.Forms.Control)

SetBounds

Overloaded. (Inherited from System.Windows.Forms.Control)

SetHelpTopic

Associates a MapItem object with a UI element.

Show

(Inherited from System.Windows.Forms.Control)

ShowDefaultTopic

Shows the topic associated with the Form where the


C1DynamicHelp control is placed.

ShowExternalHelp

Overloaded. Displays the contents of the help file in an


external help viewer window instead of in the C1DynamicHelp
panel.

ShowTopic

Overloaded. Shows the topic with the given URL in the


C1DynamicHelp control.

ShowTopicForActiveControl Shows in DisplayTarget the topic associated with the active


control (control currently in focus).
SuspendLayout

(Inherited from System.Windows.Forms.Control)

ToString

(Inherited from System.ComponentModel.Component)

Update

(Inherited from System.Windows.Forms.Control)

Top

Public Events
Name

Description

CausesValidationChanged

(Inherited from System.Windows.Forms.Control)

ClientSizeChanged

(Inherited from System.Windows.Forms.Control)

46

ContextMenuChanged

(Inherited from System.Windows.Forms.Control)

ContextMenuStripChanged (Inherited from System.Windows.Forms.Control)


ControlAdded

(Inherited from System.Windows.Forms.Control)

ControlRemoved

(Inherited from System.Windows.Forms.Control)

CurrentTopicChanged

Fires after the value of the CurrentTopic has changed.

CurrentTopicChanging

Fires before the value of the CurrentTopic changes.

Disposed

(Inherited from System.ComponentModel.Component)

DockChanged

(Inherited from System.Windows.Forms.Control)

GotFocus

(Inherited from System.Windows.Forms.Control)

HandleCreated

(Inherited from System.Windows.Forms.Control)

HandleDestroyed

(Inherited from System.Windows.Forms.Control)

Invalidated

(Inherited from System.Windows.Forms.Control)

LocationChanged

(Inherited from System.Windows.Forms.Control)

LostFocus

(Inherited from System.Windows.Forms.Control)

MarginChanged

(Inherited from System.Windows.Forms.Control)

Move

(Inherited from System.Windows.Forms.Control)

ParentChanged

(Inherited from System.Windows.Forms.Control)

PreviewKeyDown

(Inherited from System.Windows.Forms.Control)

RegionChanged

(Inherited from System.Windows.Forms.Control)

47

Resize

(Inherited from System.Windows.Forms.Control)

SizeChanged

(Inherited from System.Windows.Forms.Control)

SystemColorsChanged

(Inherited from System.Windows.Forms.Control)

TabIndexChanged

(Inherited from System.Windows.Forms.Control)

TabStopChanged

(Inherited from System.Windows.Forms.Control)

Validated

(Inherited from System.Windows.Forms.Control)

Validating

(Inherited from System.Windows.Forms.Control)

VisibleChanged

(Inherited from System.Windows.Forms.Control)

Top

See Also
Reference
C1DynamicHelp Class
C1.Win.C1DynamicHelp Namespace

C1DynamicHelp Constructor
Creates a new instance of the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Function New()
C#
public C1DynamicHelp()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also

48

Reference
C1DynamicHelp Class
C1DynamicHelp Members

Methods
>
Name

Description

BeginInvoke

Overloaded. (Inherited from System.Windows.Forms.Control)

BringToFront

(Inherited from System.Windows.Forms.Control)

Contains

(Inherited from System.Windows.Forms.Control)

CreateControl

(Inherited from System.Windows.Forms.Control)

CreateGraphics

(Inherited from System.Windows.Forms.Control)

CreateObjRef

(Inherited from System.MarshalByRefObject)

Dispose()

(Inherited from System.ComponentModel.Component)

DoDragDrop

(Inherited from System.Windows.Forms.Control)

DrawToBitmap

(Inherited from System.Windows.Forms.Control)

EndInvoke

(Inherited from System.Windows.Forms.Control)

FindForm

(Inherited from System.Windows.Forms.Control)

Focus

(Inherited from System.Windows.Forms.Control)

GetChildAtPoint

Overloaded. (Inherited from System.Windows.Forms.Control)

GetContainerControl

(Inherited from System.Windows.Forms.Control)

GetHelpTopic

Gets the MapItem object currently associated with a given UI


element.

GetLifetimeService

(Inherited from System.MarshalByRefObject)

GetNextControl

(Inherited from System.Windows.Forms.Control)

GetPreferredSize

(Inherited from System.Windows.Forms.Control)

Hide

(Inherited from System.Windows.Forms.Control)

InitializeLifetimeService

(Inherited from System.MarshalByRefObject)

Invalidate

Overloaded. (Inherited from System.Windows.Forms.Control)

49

Invoke

Overloaded. (Inherited from System.Windows.Forms.Control)

PerformLayout

Overloaded. (Inherited from System.Windows.Forms.Control)

PointToClient

(Inherited from System.Windows.Forms.Control)

PointToScreen

(Inherited from System.Windows.Forms.Control)

PreProcessControlMessage (Inherited from System.Windows.Forms.Control)


PreProcessMessage

(Inherited from System.Windows.Forms.Control)

RectangleToClient

(Inherited from System.Windows.Forms.Control)

RectangleToScreen

(Inherited from System.Windows.Forms.Control)

Refresh

(Inherited from System.Windows.Forms.Control)

ResetText

(Inherited from System.Windows.Forms.Control)

ResumeLayout

Overloaded. (Inherited from System.Windows.Forms.Control)

Scale

(Inherited from System.Windows.Forms.Control)

Select

(Inherited from System.Windows.Forms.Control)

SelectNextControl

(Inherited from System.Windows.Forms.Control)

SendToBack

(Inherited from System.Windows.Forms.Control)

SetBounds

Overloaded. (Inherited from System.Windows.Forms.Control)

SetHelpTopic

Associates a MapItem object with a UI element.

Show

(Inherited from System.Windows.Forms.Control)

ShowDefaultTopic

Shows the topic associated with the Form where the


C1DynamicHelp control is placed.

ShowExternalHelp

Overloaded. Displays the contents of the help file in an external


help viewer window instead of in the C1DynamicHelp panel.

ShowTopic

Overloaded. Shows the topic with the given URL in the


C1DynamicHelp control.

ShowTopicForActiveControl

Shows in DisplayTarget the topic associated with the active


control (control currently in focus).

SuspendLayout

(Inherited from System.Windows.Forms.Control)

ToString

(Inherited from System.ComponentModel.Component)

Update

(Inherited from System.Windows.Forms.Control)

50

Top

See Also
Reference
C1DynamicHelp Class
C1.Win.C1DynamicHelp Namespace

GetHelpTopic Method
Represents a UI element associated with a help topic.
Gets the MapItem object currently associated with a given UI element.

Syntax
Visual Basic (Declaration)
Public Function GetHelpTopic( _
ByVal uiElement As Component _
) As MapItem
C#
public MapItem GetHelpTopic(
Component uiElement
)

Parameters
uiElement
Represents a UI element associated with a help topic.

Return Value
The MapItem object associated with the specified UI element.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

51

SetHelpTopic Method
Object associated with the help topic.
The MapItem object to associate with the uiElement.
Associates a MapItem object with a UI element.

Syntax
Visual Basic (Declaration)
Public Sub SetHelpTopic( _
ByVal uiElement As Component, _
ByVal info As MapItem _
)
C#
public void SetHelpTopic(
Component uiElement,
MapItem info
)

Parameters
uiElement
Object associated with the help topic.
info
The MapItem object to associate with the uiElement.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

ShowDefaultTopic Method
Shows the topic associated with the Form where the C1DynamicHelp control is placed.

Syntax

52

Visual Basic (Declaration)


Public Sub ShowDefaultTopic()
C#
public void ShowDefaultTopic()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

ShowExternalHelp Method
Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Overload List
Overload

Description

ShowExternalHelp(HelpTab)

Displays the contents of the help file in an external help


viewer window instead of in the C1DynamicHelp panel.

ShowExternalHelp(HelpTab,Object) Displays the contents of the help file in an external help


viewer window instead of in the C1DynamicHelp panel.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

53

ShowExternalHelp(HelpTab) Method
One of the HelpTab values.
Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab _
)
C#
public void ShowExternalHelp(
HelpTab tab
)

Parameters
tab
One of the HelpTab values.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

ShowExternalHelp(HelpTab,Object) Method
One of the HelpTab values.
Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _

54

ByVal tab As HelpTab, _


ByVal parameter As Object _
)
C#
public void ShowExternalHelp(
HelpTab tab,
object parameter
)

Parameters
tab
One of the HelpTab values.
parameter

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

ShowTopic Method
Shows the topic with the given URL in the C1DynamicHelp control.

Overload List
Overload

Description

ShowTopic(String)

Shows the topic with the given URL in the C1DynamicHelp control.

ShowTopic(HelpTopic) Shows the given HelpTopic in the C1DynamicHelp control.


ShowTopic(Int32)

Shows the topic with the given context id in the C1DynamicHelp


control.

55

ShowTopic(Object)

Shows the topic associated in the TopicMap with a UI element in the


C1DynamicHelp control.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

ShowTopic(String) Method
String that represents the topic's internal URL.
Shows the topic with the given URL in the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowTopic( _
ByVal topicUrl As String _
)
C#
public void ShowTopic(
string topicUrl
)

Parameters
topicUrl
String that represents the topic's internal URL.

Exceptions
Exception

Description

System.ArgumentNullException topicUrl is null.

Requirements

56

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

ShowTopic(HelpTopic) Method
HelpTopic object representing the topic.
Shows the given HelpTopic in the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowTopic( _
ByVal topic As HelpTopic _
)
C#
public void ShowTopic(
HelpTopic topic
)

Parameters
topic
HelpTopic object representing the topic.

Exceptions
Exception

Description

System.ArgumentNullException topic is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
57

Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

ShowTopic(Int32) Method
Context id representing the topic.
Shows the topic with the given context id in the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowTopic( _
ByVal contextID As Integer _
)
C#
public void ShowTopic(
int contextID
)

Parameters
contextID
Context id representing the topic.

Exceptions
Exception

Description

System.ArgumentException specified context id is unknown.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

58

ShowTopic(Object) Method
Object associated with the topic to display.
Shows the topic associated in the TopicMap with a UI element in the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowTopic( _
ByVal uiElement As Object _
)
C#
public void ShowTopic(
object uiElement
)

Parameters
uiElement
Object associated with the topic to display.

Exceptions
Exception

Description

System.ArgumentNullException uiElement is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members
Overload List

ShowTopicForActiveControl Method
DisplayTarget where a topic will be displayed.
Shows in DisplayTarget the topic associated with the active control (control currently in focus).

59

Syntax
Visual Basic (Declaration)
Public Sub ShowTopicForActiveControl( _
ByVal displayTarget As DisplayTarget _
)
C#
public void ShowTopicForActiveControl(
DisplayTarget displayTarget
)

Parameters
displayTarget
DisplayTarget where a topic will be displayed.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Properties
%%scrap%%
" -->
For a list of all members of this type, see C1DynamicHelp members.

Public Properties
Name

Description

AccessibilityObject

(Inherited from System.Windows.Forms.Control)

AccessibleDefaultActionDescription (Inherited from System.Windows.Forms.Control)

60

AccessibleDescription

(Inherited from System.Windows.Forms.Control)

AccessibleName

(Inherited from System.Windows.Forms.Control)

AccessibleRole

(Inherited from System.Windows.Forms.Control)

Anchor

(Inherited from System.Windows.Forms.Control)

AuthoringMode

Gets or sets a value indicating whether the control is


currently in 'authoring mode'.

AutoScrollOffset

(Inherited from System.Windows.Forms.Control)

BindingContext

(Inherited from System.Windows.Forms.Control)

BorderStyle

Gets or sets the type of border to display around the


control.

Bottom

(Inherited from System.Windows.Forms.Control)

Bounds

(Inherited from System.Windows.Forms.Control)

Browser

Provides access to the browser object used to display


the topics, so the programmer can use browser
features programmatically, for example, to navigate
help topics inside the C1DynamicHelp control.

CanFocus

(Inherited from System.Windows.Forms.Control)

CanSelect

(Inherited from System.Windows.Forms.Control)

Capture

(Inherited from System.Windows.Forms.Control)

CausesValidation

(Inherited from System.Windows.Forms.Control)

ClientRectangle

(Inherited from System.Windows.Forms.Control)

ClientSize

(Inherited from System.Windows.Forms.Control)

61

CompanyName

(Inherited from System.Windows.Forms.Control)

Container

(Inherited from
System.ComponentModel.Component)

ContainsFocus

(Inherited from System.Windows.Forms.Control)

ContextMenu

Overridden. Gets or sets the shortcut menu associated


with the control.

ContextMenuStrip

Overridden. Gets or sets the


System.Windows.Forms.ContextMenuStrip associated
with this control.

Controls

(Inherited from System.Windows.Forms.Control)

Created

(Inherited from System.Windows.Forms.Control)

CurrentTopic

Gets or sets the HelpTopic that is currently displayed


by the C1DynamicHelp control.

DataBindings

(Inherited from System.Windows.Forms.Control)

DefaultTrigger

Gets or sets a default HelpTopicTrigger value for the


C1DynamicHelp control.

DisplayRectangle

(Inherited from System.Windows.Forms.Control)

Disposing

(Inherited from System.Windows.Forms.Control)

Dock

Overridden. Gets or sets which control borders are


docked to its parent control and determines how the
control is resized with its parent.

Focused

(Inherited from System.Windows.Forms.Control)

Handle

(Inherited from System.Windows.Forms.Control)

62

HasChildren

(Inherited from System.Windows.Forms.Control)

Height

(Inherited from System.Windows.Forms.Control)

HelpSource

Gets or sets the location of the help source, such as


the name of a .chm file (for HTML Help) or the name
of the main .htm file (for NetHelp).

InvokeRequired

(Inherited from System.Windows.Forms.Control)

IsAccessible

(Inherited from System.Windows.Forms.Control)

IsDisposed

(Inherited from System.Windows.Forms.Control)

IsHandleCreated

(Inherited from System.Windows.Forms.Control)

IsMirrored

(Inherited from System.Windows.Forms.Control)

IsPinnedDown

Gets or sets a value indicating whether the current


help topic is pinned down.

LayoutEngine

(Inherited from System.Windows.Forms.Control)

Left

(Inherited from System.Windows.Forms.Control)

Location

(Inherited from System.Windows.Forms.Control)

MainControl

Gets or sets a reference to another C1DynamicHelp


control which will be used as a source of data for the
current C1DynamicHelp control.

Margin

(Inherited from System.Windows.Forms.Control)

MaximumSize

(Inherited from System.Windows.Forms.Control)

MinimumSize

(Inherited from System.Windows.Forms.Control)

MouseHoverDelay

Gets or sets the interval, in milliseconds, between the

63

time the mouse enters a control or component and


the time the associated HelpTopic is displayed in the
C1DynamicHelp control.
Name

(Inherited from System.Windows.Forms.Control)

Parent

(Inherited from System.Windows.Forms.Control)

PreferredSize

(Inherited from System.Windows.Forms.Control)

ProductName

(Inherited from System.Windows.Forms.Control)

ProductVersion

(Inherited from System.Windows.Forms.Control)

Provider

Gets or sets a reference to a help provider.

RecreatingHandle

(Inherited from System.Windows.Forms.Control)

Region

(Inherited from System.Windows.Forms.Control)

Resolver

Represents a class with virtual methods that are used


to supply information about custom controls used in
the application.

Right

(Inherited from System.Windows.Forms.Control)

Site

(Inherited from System.Windows.Forms.Control)

Size

(Inherited from System.Windows.Forms.Control)

TabIndex

(Inherited from System.Windows.Forms.Control)

TabStop

(Inherited from System.Windows.Forms.Control)

Tag

(Inherited from System.Windows.Forms.Control)

Top

(Inherited from System.Windows.Forms.Control)

64

TopicMap

A dictionary that maps UI elements to MapItem


objects.

TopLevelControl

(Inherited from System.Windows.Forms.Control)

Visible

(Inherited from System.Windows.Forms.Control)

Width

(Inherited from System.Windows.Forms.Control)

Top

See Also
Reference
C1DynamicHelp Class
C1.Win.C1DynamicHelp Namespace

AuthoringMode Property
Gets or sets a value indicating whether the control is currently in 'authoring mode'.

Syntax
Visual Basic (Declaration)
Public Property AuthoringMode As Boolean
C#
public bool AuthoringMode {get; set;}

Remarks
This property allows the application user to create or modify the TopicMap at run time, and
save it to an XML file. All map items created in authoring mode have their ItemType property
set to MapItemType.Dynamic.
The map items with dynamic ItemType have precedence over the items with static
MapItem.ItemType. If a UI element appears with both dynamic and static MapItem.ItemType,
the entry with the dynamic MapItem.ItemType will be used instead of the static one.
Authoring mode is typically enabled only in special builds used by control authors to create the
dynamic topic map that is shipped with the release version of the application. In most cases,
authoring mode needs to be be disabled in the release application to prevent users from
accidentally activating the authoring mode. A typical implementation can look like this:
// toggle authoring mode when the user hits ctrl+shift+a override
protected void OnKeyDown(KeyEventArgs e) { #if AUTHOR_MODE if
(e.KeyCode == Keys.A && e.Control && e.Shift) {

65

c1DynamicHelp1.AuthoringMode = !c1DynamicHelp1.AuthoringMode; } #endif


base.OnKeyDown(e); }

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

BorderStyle Property
Gets or sets the type of border to display around the control.

Syntax
Visual Basic (Declaration)
Public Property BorderStyle As BorderStyle
C#
public BorderStyle BorderStyle {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Browser Property
Provides access to the browser object used to display the topics, so the programmer can use
browser features programmatically, for example, to navigate help topics inside the
C1DynamicHelp control.

Syntax
Visual Basic (Declaration)

66

Public ReadOnly Property Browser As WebBrowser


C#
public WebBrowser Browser {get;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

ContextMenu Property
Gets or sets the shortcut menu associated with the control.

Syntax
Visual Basic (Declaration)
Public Overrides Property ContextMenu As ContextMenu
C#
public override ContextMenu ContextMenu {get; set;}

Property Value
A System.Windows.Forms.ContextMenu that represents the shortcut menu associated with the
control.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

67

ContextMenuStrip Property
Gets or sets the System.Windows.Forms.ContextMenuStrip associated with this control.

Syntax
Visual Basic (Declaration)
Public Overrides Property ContextMenuStrip As ContextMenuStrip
C#
public override ContextMenuStrip ContextMenuStrip {get; set;}

Property Value
The System.Windows.Forms.ContextMenuStrip for this control, or null if there is no
System.Windows.Forms.ContextMenuStrip. The default is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

CurrentTopic Property
Gets or sets the HelpTopic that is currently displayed by the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Property CurrentTopic As HelpTopic
C#
public HelpTopic CurrentTopic {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

68

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

DefaultTrigger Property
Gets or sets a default HelpTopicTrigger value for the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Property DefaultTrigger As HelpTopicTrigger
C#
public HelpTopicTrigger DefaultTrigger {get; set;}

Remarks
All map items in the TopicMap that have their MapItem.UseDefaultTrigger property set to true
(default) display their topic when the event specified in the DefaultTrigger property occurs. Map
items that have MapItem.UseDefaultTrigger = false specify their triggers individually in
HelpTopicTrigger.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Dock Property
Gets or sets which control borders are docked to its parent control and determines how the
control is resized with its parent.

Syntax
Visual Basic (Declaration)
Public Overrides Property Dock As DockStyle

69

C#
public override DockStyle Dock {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

HelpSource Property
Gets or sets the location of the help source, such as the name of a .chm file (for HTML Help) or
the name of the main .htm file (for NetHelp).

Syntax
Visual Basic (Declaration)
Public Property HelpSource As String
C#
public string HelpSource {get; set;}

Remarks
The name of the file may be absolute or relative. In most cases, the name will be relative and
will refer to the application's bin folder.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

IsPinnedDown Property
Gets or sets a value indicating whether the current help topic is pinned down.

70

Syntax
Visual Basic (Declaration)
Public Property IsPinnedDown As Boolean
C#
public bool IsPinnedDown {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

MainControl Property
Gets or sets a reference to another C1DynamicHelp control which will be used as a source of
data for the current C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Property MainControl As C1DynamicHelp
C#
public C1DynamicHelp MainControl {get; set;}

Remarks
The current C1DynamicHelp control will use the MainControl's properties: HelpSource, Resolver,
Provider, etc instead of its own properties. It is used to place C1DynamicHelp controls on
multiple forms that will display topics from one help source. In this case you will have one main
C1DynamicHelp control and set properties for it, and all you need to do for the other
C1DynamicHelp controls is to set their MainControl property to the main C1DynamicHelp
control.

Requirements

71

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

MouseHoverDelay Property
Gets or sets the interval, in milliseconds, between the time the mouse enters a control or
component and the time the associated HelpTopic is displayed in the C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Property MouseHoverDelay As Integer
C#
public int MouseHoverDelay {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Provider Property
Gets or sets a reference to a help provider.

Syntax
Visual Basic (Declaration)
Public Property Provider As IHelpProvider
C#
public IHelpProvider Provider {get; set;}

72

Exceptions
Exception

Description

System.ArgumentNullException Provider cannot be null.

Remarks
You should set this property only if you implement your own help provider class (an advanced
feature). A help provider can read data from a help source and provides methods to get a help
topic list, to get a dictionary of context ids and help topics, to open help in an external window,
to get a topic URL that can be displayed in a C1DynamicHelp control, etc.
There are two built-in help providers in C1DynamicHelp: ChmProvider and NetHelpProvider
which are used automatically when the HelpSource property points to a .chm or .html/.htm file
correspondingly.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Resolver Property
Represents a class with virtual methods that are used to supply information about custom
controls used in the application.

Syntax
Visual Basic (Declaration)
Public Property Resolver As UIElementResolver
C#
public UIElementResolver Resolver {get; set;}

Remarks
This property must be set only if custom/third-party controls are used in the application and it
is necessary to associate help with parts of such controls (called UI elements, for example,
buttons on a custom ribbon control). It should provide a way to get the Name and Parent for

73

every UI element, get a UI element inside the control by coordinates, get a UI element inside
the control by name, etc.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

TopicMap Property
A dictionary that maps UI elements to MapItem objects.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property TopicMap As TopicMap
C#
public TopicMap TopicMap {get;}

Remarks
A MapItem object specifies a help topic to display and a user action that causes the display
(control getting focus, mouse hovering). This dictionary can be created at design time and
persisted as part of the form (called static mappings), or at run-time (using the controls
authoring mode) and persisted as an XML file (called dynamic mappings).
This property enables you to obtain a reference to the topic map items that are currently stored
in the C1DynamicHelp. With this reference, you can add items, remove items, and obtain a
count of the items in the collection. The TopicMap class has members that allow users to check
whether the map has changed since it was created and to persist the map to and from XML.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

74

C1DynamicHelp Class
C1DynamicHelp Members

Events
%%scrap%%
" -->
For a list of all members of this type, see C1DynamicHelp members.

Public Events
Name

Description

CausesValidationChanged

(Inherited from System.Windows.Forms.Control)

ClientSizeChanged

(Inherited from System.Windows.Forms.Control)

ContextMenuChanged

(Inherited from System.Windows.Forms.Control)

ContextMenuStripChanged (Inherited from System.Windows.Forms.Control)


ControlAdded

(Inherited from System.Windows.Forms.Control)

ControlRemoved

(Inherited from System.Windows.Forms.Control)

CurrentTopicChanged

Fires after the value of the CurrentTopic has changed.

CurrentTopicChanging

Fires before the value of the CurrentTopic changes.

Disposed

(Inherited from System.ComponentModel.Component)

DockChanged

(Inherited from System.Windows.Forms.Control)

GotFocus

(Inherited from System.Windows.Forms.Control)

HandleCreated

(Inherited from System.Windows.Forms.Control)

HandleDestroyed

(Inherited from System.Windows.Forms.Control)

Invalidated

(Inherited from System.Windows.Forms.Control)

75

LocationChanged

(Inherited from System.Windows.Forms.Control)

LostFocus

(Inherited from System.Windows.Forms.Control)

MarginChanged

(Inherited from System.Windows.Forms.Control)

Move

(Inherited from System.Windows.Forms.Control)

ParentChanged

(Inherited from System.Windows.Forms.Control)

PreviewKeyDown

(Inherited from System.Windows.Forms.Control)

RegionChanged

(Inherited from System.Windows.Forms.Control)

Resize

(Inherited from System.Windows.Forms.Control)

SizeChanged

(Inherited from System.Windows.Forms.Control)

SystemColorsChanged

(Inherited from System.Windows.Forms.Control)

TabIndexChanged

(Inherited from System.Windows.Forms.Control)

TabStopChanged

(Inherited from System.Windows.Forms.Control)

Validated

(Inherited from System.Windows.Forms.Control)

Validating

(Inherited from System.Windows.Forms.Control)

VisibleChanged

(Inherited from System.Windows.Forms.Control)

Top

See Also
Reference
C1DynamicHelp Class
C1.Win.C1DynamicHelp Namespace

CurrentTopicChanged Event
Fires after the value of the CurrentTopic has changed.

76

Syntax
Visual Basic (Declaration)
Public Event CurrentTopicChanged As EventHandler
C#
public event EventHandler CurrentTopicChanged

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

CurrentTopicChanging Event
Fires before the value of the CurrentTopic changes.

Syntax
Visual Basic (Declaration)
Public Event CurrentTopicChanging As HelpTopicEventHandler
C#
public event HelpTopicEventHandler CurrentTopicChanging

Event Data
The event handler receives an argument of type TopicEventArgs containing data related to this
event. The following TopicEventArgs properties provide information specific to this event.
Property

Description

Cancel

Gets or sets a value indicating whether the event should be canceled.

Topic

Gets a value indicating the help topic becoming current.

Requirements
77

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1DynamicHelp Class
C1DynamicHelp Members

Conflict
Class used in the TopicMap.Conflicts property of the TopicMap.

Object Model

Syntax
Visual Basic (Declaration)
Public Class Conflict
C#
public class Conflict

Remarks
This class contains data describing a conflict between two map items, one static, the other
dynamic. A conflict exists between two map items if they refer to the same UI element.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Conflict

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
Conflict Members
C1.Win.C1DynamicHelp Namespace

78

Overview
Class used in the TopicMap.Conflicts property of the TopicMap.

Object Model

Syntax
Visual Basic (Declaration)
Public Class Conflict
C#
public class Conflict

Remarks
This class contains data describing a conflict between two map items, one static, the other
dynamic. A conflict exists between two map items if they refer to the same UI element.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Conflict

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
Conflict Members
C1.Win.C1DynamicHelp Namespace

Members
Properties

The following tables list the members exposed by Conflict.

Public Properties
Name

Description

79

DynamicItem

Returns the dynamic map item.

Name

Returns the name of the UI element (serving as the identifier of the static
map item).

StaticItem

Returns the static map item.

UIElementPath

Returns the UI element's path string (serving as the identifier of the


dynamic map item).

Top

See Also
Reference
Conflict Class
C1.Win.C1DynamicHelp Namespace

Properties
%%scrap%%
" -->
For a list of all members of this type, see Conflict members.

Public Properties
Name

Description

DynamicItem

Returns the dynamic map item.

Name

Returns the name of the UI element (serving as the identifier of the static
map item).

StaticItem

Returns the static map item.

UIElementPath

Returns the UI element's path string (serving as the identifier of the


dynamic map item).

Top

See Also
Reference

80

Conflict Class
C1.Win.C1DynamicHelp Namespace

DynamicItem Property
Returns the dynamic map item.

Syntax
Visual Basic (Declaration)
Public Property DynamicItem As MapItem
C#
public MapItem DynamicItem {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
Conflict Class
Conflict Members

Name Property
Returns the name of the UI element (serving as the identifier of the static map item).

Syntax
Visual Basic (Declaration)
Public Property Name As String
C#
public string Name {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also

81

Reference
Conflict Class
Conflict Members

StaticItem Property
Returns the static map item.

Syntax
Visual Basic (Declaration)
Public Property StaticItem As MapItem
C#
public MapItem StaticItem {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
Conflict Class
Conflict Members

UIElementPath Property
Returns the UI element's path string (serving as the identifier of the dynamic map item).

Syntax
Visual Basic (Declaration)
Public Property UIElementPath As String
C#
public string UIElementPath {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

82

See Also
Reference
Conflict Class
Conflict Members

HelpTopic
Represents a topic in a help file.

Object Model

Syntax
Visual Basic (Declaration)
Public Class HelpTopic
C#
public class HelpTopic

Remarks
You need to explicitly create HelpTopic objects in your code only if you implement your own
help provider.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.HelpTopic

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Members
C1.Win.C1DynamicHelp Namespace

Overview
Represents a topic in a help file.

83

Object Model

Syntax
Visual Basic (Declaration)
Public Class HelpTopic
C#
public class HelpTopic

Remarks
You need to explicitly create HelpTopic objects in your code only if you implement your own
help provider.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.HelpTopic

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Members
C1.Win.C1DynamicHelp Namespace

Members
Properties Methods

The following tables list the members exposed by HelpTopic.

Public Constructors
Name

Description

HelpTopic Constructor Overloaded.


Top

84

Public Properties
Name

Description

ContextID

Gets the unique numeric ID of the topic within the help system used for
context sensitive help purposes.

SubTopics

Gets the list of child topics.

Title

Gets the name of the help topic.

Url

Gets the topic URL relative to the help source.

Top

Public Methods
Name

Description

SetCtxtId

Set context ID for this HelpTopic.

ToString

Gets a string representation of this HelpTopic.

Top

See Also
Reference
HelpTopic Class
C1.Win.C1DynamicHelp Namespace

HelpTopic Constructor
Overload List
Overload

Description

HelpTopic Constructor(String,String,HelpTopicList) Creates a new instance of HelpTopic.


HelpTopic Constructor(String,String)

Creates a new instance of HelpTopic.

Requirements

85

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

HelpTopic Constructor(String,String,HelpTopicList)
A title for the help topic being created.
A URL for the help topic being created.
Child topics for the topic being created.
Creates a new instance of HelpTopic.

Syntax
Visual Basic (Declaration)
Public Function New( _
ByVal title As String, _
ByVal url As String, _
ByVal subtopics As HelpTopicList _
)
C#
public HelpTopic(
string title,
string url,
HelpTopicList subtopics
)

Parameters
title
A title for the help topic being created.
url
A URL for the help topic being created.
subtopics
Child topics for the topic being created.

86

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2
(Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members
Overload List

HelpTopic Constructor(String,String)
A title for the help topic being created.
A URL for the help topic being created.
Creates a new instance of HelpTopic.

Syntax
Visual Basic (Declaration)
Public Function New( _
ByVal title As String, _
ByVal url As String _
)
C#
public HelpTopic(
string title,
string url
)

Parameters
title
A title for the help topic being created.
url
A URL for the help topic being created.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

87

See Also
Reference
HelpTopic Class
HelpTopic Members
Overload List

Methods
%%scrap%%
" -->
For a list of all members of this type, see HelpTopic members.

Public Methods
Name

Description

SetCtxtId

Set context ID for this HelpTopic.

ToString

Gets a string representation of this HelpTopic.

Top

See Also
Reference
HelpTopic Class
C1.Win.C1DynamicHelp Namespace

SetCtxtId Method
Context ID for thisHelpTopic.
Set context ID for this HelpTopic.

Syntax
Visual Basic (Declaration)
Public Sub SetCtxtId( _
ByVal ctxtId As Integer _
)
C#
public void SetCtxtId(
int ctxtId

88

Parameters
ctxtId
Context ID for thisHelpTopic.

Remarks
This method should be used only for creating you own help provider class.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

ToString Method
Gets a string representation of this HelpTopic.

Syntax
Visual Basic (Declaration)
Public Overrides Function ToString() As String
C#
public override string ToString()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

89

Properties
%%scrap%%
" -->
For a list of all members of this type, see HelpTopic members.

Public Properties
Name

Description

ContextID

Gets the unique numeric ID of the topic within the help system used for
context sensitive help purposes.

SubTopics

Gets the list of child topics.

Title

Gets the name of the help topic.

Url

Gets the topic URL relative to the help source.

Top

See Also
Reference
HelpTopic Class
C1.Win.C1DynamicHelp Namespace

ContextID Property
Gets the unique numeric ID of the topic within the help system used for context sensitive help
purposes.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property ContextID As Integer
C#
public int ContextID {get;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

90

See Also
Reference
HelpTopic Class
HelpTopic Members

SubTopics Property
Gets the list of child topics.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property SubTopics As HelpTopicList
C#
public HelpTopicList SubTopics {get;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

Title Property
Gets the name of the help topic.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property Title As String
C#
public string Title {get;}

Requirements

91

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

Url Property
Gets the topic URL relative to the help source.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property Url As String
C#
public string Url {get;}

Remarks
Since this is the relative URL, the help viewer/browser may be unable to display topics given
only that URL. Full URL can be obtained from the IHelpProvider.GetFullUrl method.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopic Class
HelpTopic Members

HelpTopicList
List of HelpTopic objects.

Object Model

Syntax
92

Visual Basic (Declaration)


Public Class HelpTopicList
Inherits System.Collections.Generic.List(Of HelpTopic)
C#
public class HelpTopicList : System.Collections.Generic.List<HelpTopic>

Inheritance Hierarchy
System.Object
System.Collections.Generic.List<T>
C1.Win.C1DynamicHelp.HelpTopicList

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopicList Members
C1.Win.C1DynamicHelp Namespace

Overview
List of HelpTopic objects.

Object Model

Syntax
Visual Basic (Declaration)
Public Class HelpTopicList
Inherits System.Collections.Generic.List(Of HelpTopic)
C#
public class HelpTopicList : System.Collections.Generic.List<HelpTopic>

Inheritance Hierarchy

93

System.Object
System.Collections.Generic.List<T>
C1.Win.C1DynamicHelp.HelpTopicList

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopicList Members
C1.Win.C1DynamicHelp Namespace

Members
Properties Methods

The following tables list the members exposed by HelpTopicList.

Public Constructors
Name

Description

HelpTopicList Constructor
Top

Public Properties
Name

Description

Capacity

(Inherited from System.Collections.Generic.List<HelpTopic>)

Count

(Inherited from System.Collections.Generic.List<HelpTopic>)

Item

(Inherited from System.Collections.Generic.List<HelpTopic>)

Top

Public Methods
Name

Description

Add

(Inherited from System.Collections.Generic.List<HelpTopic>)

94

AddRange

(Inherited from System.Collections.Generic.List<HelpTopic>)

AsReadOnly

(Inherited from System.Collections.Generic.List<HelpTopic>)

BinarySearch

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

Clear

(Inherited from System.Collections.Generic.List<HelpTopic>)

Contains

(Inherited from System.Collections.Generic.List<HelpTopic>)

ConvertAll

(Inherited from System.Collections.Generic.List<HelpTopic>)

CopyTo

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

Exists

(Inherited from System.Collections.Generic.List<HelpTopic>)

Find

(Inherited from System.Collections.Generic.List<HelpTopic>)

FindAll

(Inherited from System.Collections.Generic.List<HelpTopic>)

FindIndex

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

FindLast

(Inherited from System.Collections.Generic.List<HelpTopic>)

FindLastIndex

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

ForEach

(Inherited from System.Collections.Generic.List<HelpTopic>)

GetEnumerator

(Inherited from System.Collections.Generic.List<HelpTopic>)

GetRange

(Inherited from System.Collections.Generic.List<HelpTopic>)

IndexOf

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

Insert

(Inherited from System.Collections.Generic.List<HelpTopic>)

InsertRange

(Inherited from System.Collections.Generic.List<HelpTopic>)

95

LastIndexOf

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

Remove

(Inherited from System.Collections.Generic.List<HelpTopic>)

RemoveAll

(Inherited from System.Collections.Generic.List<HelpTopic>)

RemoveAt

(Inherited from System.Collections.Generic.List<HelpTopic>)

RemoveRange

(Inherited from System.Collections.Generic.List<HelpTopic>)

Reverse

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

Sort

Overloaded. (Inherited from System.Collections.Generic.List<HelpTopic>)

ToArray

(Inherited from System.Collections.Generic.List<HelpTopic>)

TrimExcess

(Inherited from System.Collections.Generic.List<HelpTopic>)

TrueForAll

(Inherited from System.Collections.Generic.List<HelpTopic>)

Top

See Also
Reference
HelpTopicList Class
C1.Win.C1DynamicHelp Namespace

HelpTopicList Constructor
Syntax
Visual Basic (Declaration)
Public Function New()
C#
public HelpTopicList()

Requirements

96

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
HelpTopicList Class
HelpTopicList Members

MapItem
Class containing a pair consisting of a topic and a user action triggering its display.

Object Model

Syntax
Visual Basic (Declaration)
Public Class MapItem
C#
public class MapItem

Remarks
Objects of this class are stored in the TopicMap dictionary. Map items are created automatically
at design time and in authoring mode. You can also create them at run time programmatically.
Map items created at design time have their ItemType property set to MapItemType.Static,
whereas map items created in authoring mode have their ItemType property set to
MapItemType.Dynamic. If you create a map item programmatically, you can set this property to
any of the two values.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.MapItem

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also

97

Reference
MapItem Members
C1.Win.C1DynamicHelp Namespace

Overview
Class containing a pair consisting of a topic and a user action triggering its display.

Object Model

Syntax
Visual Basic (Declaration)
Public Class MapItem
C#
public class MapItem

Remarks
Objects of this class are stored in the TopicMap dictionary. Map items are created automatically
at design time and in authoring mode. You can also create them at run time programmatically.
Map items created at design time have their ItemType property set to MapItemType.Static,
whereas map items created in authoring mode have their ItemType property set to
MapItemType.Dynamic. If you create a map item programmatically, you can set this property to
any of the two values.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.MapItem

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Members
C1.Win.C1DynamicHelp Namespace

98

Members
" -->

Public Constructors
Name

Description

MapItem Constructor Initializes a new of instance of a MapItem


Top

Public Properties
Name

Description

HelpTopic

Gets the HelpTopic object by the Url value.

HelpTopicTrigger

Specifies what triggers the topic display.

ItemType

Gets or sets an item type.

Gets or sets a value indicating whether the default topic (the topic
associated with the form) should be always displayed when the form
ShowDefaultTopicFirst
is loaded and becomes visible, even if a UI element inside the form
got focus and has a topic associated with it.
UIElement

Gets or sets a UI element for which a help topic is displayed.

Url

Gets or sets the URL of a help topic that will be displayed.


Gets or sets a value indicating whether a topic will be displayed
depending on its own HelpTopicTrigger value or on the
C1DynamicHelp.DefaultTrigger value of the C1DynamicHelp control.

UseDefaultTrigger

Top

Public Methods
Name
ToString

Description
Returns a string representation of a MapItem, which is the topic URL.

Top

See Also
Reference
MapItem Class
C1.Win.C1DynamicHelp Namespace

99

MapItem Constructor
Initializes a new of instance of a MapItem

Syntax
Visual Basic (Declaration)
Public Function New()
C#
public MapItem()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

Methods
>
Name
ToString

Description
Returns a string representation of a MapItem, which is the topic URL.

Top

See Also
Reference
MapItem Class
C1.Win.C1DynamicHelp Namespace

ToString Method
Returns a string representation of a MapItem, which is the topic URL.

Syntax
Visual Basic (Declaration)
Public Overrides Function ToString() As String

100

C#
public override string ToString()

Return Value
A System.String that represents the current MapItem.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

Properties
%%scrap%%
" -->
For a list of all members of this type, see MapItem members.

Public Properties
Name

Description

HelpTopic

Gets the HelpTopic object by the Url value.

HelpTopicTrigger

Specifies what triggers the topic display.

ItemType

Gets or sets an item type.

ShowDefaultTopicFirst Gets or sets a value indicating whether the default topic (the topic
associated with the form) should be always displayed when the
form is loaded and becomes visible, even if a UI element inside the
form got focus and has a topic associated with it.
UIElement

Gets or sets a UI element for which a help topic is displayed.

Url

Gets or sets the URL of a help topic that will be displayed.

101

UseDefaultTrigger

Gets or sets a value indicating whether a topic will be displayed


depending on its own HelpTopicTrigger value or on the
C1DynamicHelp.DefaultTrigger value of the C1DynamicHelp
control.

Top

See Also
Reference
MapItem Class
C1.Win.C1DynamicHelp Namespace

HelpTopic Property
Gets the HelpTopic object by the Url value.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property HelpTopic As HelpTopic
C#
public HelpTopic HelpTopic {get;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

HelpTopicTrigger Property
Specifies what triggers the topic display.

Syntax
Visual Basic (Declaration)
Public Property HelpTopicTrigger As HelpTopicTrigger

102

C#
public HelpTopicTrigger HelpTopicTrigger {get; set;}

Remarks
This property is used only if the UseDefaultTrigger property is set to false. If UseDefaultTrigger
is set to true, this property is ignored and C1DynamicHelp.DefaultTrigger property is used
instead.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

ItemType Property
Gets or sets an item type.

Syntax
Visual Basic (Declaration)
Public Property ItemType As MapItemType
C#
public MapItemType ItemType {get; set;}

Remarks
Items with MapItemType.Dynamic are created in authoring mode and saved to an XML file.
Items with MapItemType.Static are created at design time and persisted as part of the form.
Items of both types can be created programmatically at run time.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also

103

Reference
MapItem Class
MapItem Members

ShowDefaultTopicFirst Property
Gets or sets a value indicating whether the default topic (the topic associated with the form)
should be always displayed when the form is loaded and becomes visible, even if a UI element
inside the form got focus and has a topic associated with it.

Syntax
Visual Basic (Declaration)
Public Property ShowDefaultTopicFirst As Boolean
C#
public bool ShowDefaultTopicFirst {get; set;}

Remarks
This property is used only for top level controls (Form objects), it is ignored for other UI
elements.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

UIElement Property
Gets or sets a UI element for which a help topic is displayed.

Syntax
Visual Basic (Declaration)
Public Property UIElement As Object
C#
public object UIElement {get; set;}

104

Remarks
This property should be set only once and shouldn't be changed after that.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

Url Property
Gets or sets the URL of a help topic that will be displayed.

Syntax
Visual Basic (Declaration)
Public Property Url As String
C#
public string Url {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

UseDefaultTrigger Property
Gets or sets a value indicating whether a topic will be displayed depending on its own
HelpTopicTrigger value or on the C1DynamicHelp.DefaultTrigger value of the C1DynamicHelp
control.

Syntax

105

Visual Basic (Declaration)


Public Property UseDefaultTrigger As Boolean
C#
public bool UseDefaultTrigger {get; set;}

Remarks
If this property is set to false, the HelpTopicTrigger property is used to determine when the
topic should be shown. Otherwise, the C1DynamicHelp.DefaultTrigger value determines when
the topic will be displayed.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
MapItem Class
MapItem Members

TopicEventArgs
Provides data for a topic change event.

Object Model

Syntax
Visual Basic (Declaration)
Public Class TopicEventArgs
Inherits System.ComponentModel.CancelEventArgs
C#
public class TopicEventArgs : System.ComponentModel.CancelEventArgs

Inheritance Hierarchy
System.Object
System.EventArgs

106

System.ComponentModel.CancelEventArgs
C1.Win.C1DynamicHelp.TopicEventArgs

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicEventArgs Members
C1.Win.C1DynamicHelp Namespace

Overview
Provides data for a topic change event.

Object Model

Syntax
Visual Basic (Declaration)
Public Class TopicEventArgs
Inherits System.ComponentModel.CancelEventArgs
C#
public class TopicEventArgs : System.ComponentModel.CancelEventArgs

Inheritance Hierarchy
System.Object
System.EventArgs
System.ComponentModel.CancelEventArgs
C1.Win.C1DynamicHelp.TopicEventArgs

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

107

TopicEventArgs Members
C1.Win.C1DynamicHelp Namespace

Members
Properties

The following tables list the members exposed by TopicEventArgs.

Public Properties
Name

Description

Cancel

Gets or sets a value indicating whether the event should be canceled.

Topic

Gets a value indicating the help topic becoming current.

Top

See Also
Reference
TopicEventArgs Class
C1.Win.C1DynamicHelp Namespace

Properties
>
Name

Description

Cancel

Gets or sets a value indicating whether the event should be canceled.

Topic

Gets a value indicating the help topic becoming current.

Top

See Also
Reference
TopicEventArgs Class
C1.Win.C1DynamicHelp Namespace

Cancel Property
Gets or sets a value indicating whether the event should be canceled.

Syntax
Visual Basic (Declaration)

108

Public Shadows Property Cancel As Boolean


C#
public new bool Cancel {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicEventArgs Class
TopicEventArgs Members

Topic Property
Gets a value indicating the help topic becoming current.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property Topic As HelpTopic
C#
public HelpTopic Topic {get;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicEventArgs Class
TopicEventArgs Members

TopicMap
Class used to store combinations of topics and user actions that cause their display.

Object Model

109

Syntax
Visual Basic (Declaration)
Public Class TopicMap
Inherits System.Collections.Generic.Dictionary(Of Object,MapItem)
C#
public class TopicMap : System.Collections.Generic.Dictionary<object,MapItem>

Remarks
This class is a dictionary that associates UI elements to MapItem objects that specify a help
topic to display and the user action that causes the display (control getting focus, mouse
hovering).
This class allows you to add items, remove items, and obtain a count of the items in the
collection. The TopicMap class has members that allow users to check whether the map has
changed since it was created and to persist the map to and from XML.
It can contain items of two different types: MapItemType.Dynamic and MapItemType.Static.
Map items with dynamic type are created in authoring mode, and only items of this type can be
saved to an XML file with the Save method and then loaded with the Load method. As opposed
to dynamic map items, static map items are created at design time and aren't saved to or
loaded from XML file.
Dynamic map items use a "control path" string (the name of the UI element itself prepended
with the names of all its ancestors up to the form level) as the UI element identifier. So, if you
include controls that are created dynamically, at run time, you need to call the Refresh method
that finds UI elements by their "control path" and adds them to the dynamic help system. As the
controls on the form can be created dynamically, you may need to call the Refresh method
more than once (or, for example, it can be done on timer).

Inheritance Hierarchy
System.Object
System.Collections.Generic.Dictionary<TKey,TValue>
C1.Win.C1DynamicHelp.TopicMap

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also

110

Reference
TopicMap Members
C1.Win.C1DynamicHelp Namespace

Overview
Class used to store combinations of topics and user actions that cause their display.

Object Model

Syntax
Visual Basic (Declaration)
Public Class TopicMap
Inherits System.Collections.Generic.Dictionary(Of Object,MapItem)
C#
public class TopicMap : System.Collections.Generic.Dictionary<object,MapItem>

Remarks
This class is a dictionary that associates UI elements to MapItem objects that specify a help
topic to display and the user action that causes the display (control getting focus, mouse
hovering).
This class allows you to add items, remove items, and obtain a count of the items in the
collection. The TopicMap class has members that allow users to check whether the map has
changed since it was created and to persist the map to and from XML.
It can contain items of two different types: MapItemType.Dynamic and MapItemType.Static.
Map items with dynamic type are created in authoring mode, and only items of this type can be
saved to an XML file with the Save method and then loaded with the Load method. As opposed
to dynamic map items, static map items are created at design time and aren't saved to or
loaded from XML file.
Dynamic map items use a "control path" string (the name of the UI element itself prepended
with the names of all its ancestors up to the form level) as the UI element identifier. So, if you
include controls that are created dynamically, at run time, you need to call the Refresh method
that finds UI elements by their "control path" and adds them to the dynamic help system. As the
controls on the form can be created dynamically, you may need to call the Refresh method
more than once (or, for example, it can be done on timer).

Inheritance Hierarchy

111

System.Object
System.Collections.Generic.Dictionary<TKey,TValue>
C1.Win.C1DynamicHelp.TopicMap

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Members
C1.Win.C1DynamicHelp Namespace

Members
Properties Methods Events

The following tables list the members exposed by TopicMap.

Public Properties
Name

Description

Comparer

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

Conflicts

Gets an array of conflicting map items.

Count

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

HasChanges

Gets a value that determines whether the TopicMap has changed since it
was initialized (read from an XML file).

Item

Gets or sets the value associated with the specified key.

Keys

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

Values

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

XmlSource

Gets or sets an System.Xml.XmlDocument value representing a TopicMap


created in authoring mode (so it consists of dynamic map items, static
map items aren't included), which is saved to an XML file.

112

Top

Public Methods
Name

Description

Add

Overloaded. Adds the specified uiElement and value to the TopicMap.

Clear

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Contains

Determines whether the TopicMap contains the specified key.

ContainsKey

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

ContainsValue

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

GetEnumerator

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

GetObjectData

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Load

Overloaded. Loads the TopicMap contents from an XML file.

OnDeserialization (Inherited from


System.Collections.Generic.Dictionary<object,MapItem>)
Refresh

Refreshes topic map items with the ItemType property set to


MapItemType.Dynamic. For every control path in the map that does not
yet have a UI element found for it, it tries to find a UI element.

Remove

Overloaded. Removes the value with the specified uiElement from the
TopicMap

Save

Overloaded. Saves the TopicMap contents to an XML file with the same
name as the HelpSource with .xml extension.

113

TryGetValue

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Top

Public Events
Name

Description

TopicMapChanged Fires after changes were made in the topic map.


TopicMapSaved

Fires after the topic map is saved to an XML file.

Top

See Also
Reference
TopicMap Class
C1.Win.C1DynamicHelp Namespace

Methods
%%scrap%%
" -->
For a list of all members of this type, see TopicMap members.

Public Methods
Name

Description

Add

Overloaded. Adds the specified uiElement and value to the TopicMap.

Clear

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Contains

Determines whether the TopicMap contains the specified key.

ContainsKey

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

ContainsValue

(Inherited from

114

System.Collections.Generic.Dictionary<object,MapItem>)
GetEnumerator

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

GetObjectData

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Load

Overloaded. Loads the TopicMap contents from an XML file.

OnDeserialization (Inherited from


System.Collections.Generic.Dictionary<object,MapItem>)
Refresh

Refreshes topic map items with the ItemType property set to


MapItemType.Dynamic. For every control path in the map that does not
yet have a UI element found for it, it tries to find a UI element.

Remove

Overloaded. Removes the value with the specified uiElement from the
TopicMap

Save

Overloaded. Saves the TopicMap contents to an XML file with the same
name as the HelpSource with .xml extension.

TryGetValue

(Inherited from
System.Collections.Generic.Dictionary<object,MapItem>)

Top

See Also
Reference
TopicMap Class
C1.Win.C1DynamicHelp Namespace

Add Method
Adds the specified uiElement and value to the TopicMap.

Overload List
Overload

Description

115

Add(Object,MapItem) Adds the specified uiElement and value to the TopicMap.


Add(String,MapItem)

Adds the specified path and value to the TopicMap.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Add(Object,MapItem) Method
The key of the element to add.
The value of the element to add.
Adds the specified uiElement and value to the TopicMap.

Syntax
Visual Basic (Declaration)
Public Overloads Shadows Sub Add( _
ByVal uiElement As Object, _
ByVal info As MapItem _
)
C#
public new void Add(
object uiElement,
MapItem info
)

Parameters
uiElement
The key of the element to add.
info
The value of the element to add.

116

Exceptions
Exception

Description

System.ArgumentNullException uiElement or info is null


System.ArgumentException

An element with the same uiElement already exists in the


TopicMap.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Add(String,MapItem) Method
The key of the element to add.
The value of the element to add.
Adds the specified path and value to the TopicMap.

Syntax
Visual Basic (Declaration)
Public Overloads Sub Add( _
ByVal path As String, _
ByVal info As MapItem _
)
C#
public void Add(
string path,
MapItem info
)

Parameters
path

117

The key of the element to add.


info
The value of the element to add.

Exceptions
Exception

Description

System.ArgumentNullException path or info is null


System.ArgumentException

An element with the same path already exists in the TopicMap.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Contains Method
The key to locate in the TopicMap.
Determines whether the TopicMap contains the specified key.

Syntax
Visual Basic (Declaration)
Public Function Contains( _
ByVal path As String _
) As Boolean
C#
public bool Contains(
string path
)

Parameters
path

118

The key to locate in the TopicMap.

Return Value
true if the TopicMap contains an element with the specified key; otherwise, false.

Exceptions
Exception

Description

System.ArgumentNullException path is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Load Method
Loads the TopicMap contents from an XML file.

Overload List
Overload

Description

Load(String)

Loads the TopicMap contents from an XML file.

Load()

Loads the TopicMap contents from an XML file with the same name as the
HelpSource with .xml extension.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

119

Load(String) Method
The location of the file containing a topic map.
Loads the TopicMap contents from an XML file.

Syntax
Visual Basic (Declaration)
Public Overloads Sub Load( _
ByVal fileName As String _
)
C#
public void Load(
string fileName
)

Parameters
fileName
The location of the file containing a topic map.

Remarks
All items loaded with this method will have ItemType property set to
MapItemType.Dynamic.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Load() Method
Loads the TopicMap contents from an XML file with the same name as the HelpSource with .xml
extension.

Syntax

120

Visual Basic (Declaration)


Public Overloads Sub Load()
C#
public void Load()

Remarks
All items loaded with this method will have ItemType property set to MapItemType.Dynamic.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Refresh Method
Refreshes topic map items with the ItemType property set to MapItemType.Dynamic. For every
control path in the map that does not yet have a UI element found for it, it tries to find a UI
element.

Syntax
Visual Basic (Declaration)
Public Sub Refresh()
C#
public void Refresh()

Remarks
If a UI element is found, it is added to the dynamic help system, that is, the events (focus
enter/leave, mouse hover) for it are monitored and the associated topic is shown when
triggered by those events.

Requirements

121

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Remove Method
Removes the value with the specified uiElement from the TopicMap

Overload List
Overload

Description

Remove(Object)

Removes the value with the specified uiElement from the TopicMap

Remove(String)

Removes the value with the specified path from the TopicMap

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Remove(Object) Method
The key of the element to remove.
Removes the value with the specified uiElement from the TopicMap

Syntax
Visual Basic (Declaration)
Public Overloads Shadows Sub Remove( _
ByVal uiElement As Object _
)
C#

122

public new void Remove(


object uiElement
)

Parameters
uiElement
The key of the element to remove.

Exceptions
Exception

Description

System.ArgumentNullException uiElement is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Remove(String) Method
The key of the element to remove.
Removes the value with the specified path from the TopicMap

Syntax
Visual Basic (Declaration)
Public Overloads Sub Remove( _
ByVal path As String _
)
C#
public void Remove(
string path
)

Parameters
123

path
The key of the element to remove.

Exceptions
Exception

Description

System.ArgumentNullException path is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Save Method
Saves the TopicMap contents to an XML file with the same name as the HelpSource with .xml
extension.

Overload List
Overload

Description

Save()

Saves the TopicMap contents to an XML file with the same name as the
HelpSource with .xml extension.

Save(String)

Saves the TopicMap contents to an XML file with a given name/location.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

124

Save() Method
Saves the TopicMap contents to an XML file with the same name as the HelpSource with .xml
extension.

Syntax
Visual Basic (Declaration)
Public Overloads Sub Save()
C#
public void Save()

Remarks
Only map items with ItemType set to MapItemType.Dynamic are saved to the XML file.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Save(String) Method
The location of the file where you want to save the topic map.
Saves the TopicMap contents to an XML file with a given name/location.

Syntax
Visual Basic (Declaration)
Public Overloads Sub Save( _
ByVal fileName As String _
)
C#
public void Save(
string fileName

125

Parameters
fileName
The location of the file where you want to save the topic map.

Remarks
Only map items with ItemType set to MapItemType.Dynamic are saved to the XML file.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members
Overload List

Properties
%%scrap%%
" -->
For a list of all members of this type, see TopicMap members.

Public Properties
Name

Description

Comparer

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

Conflicts

Gets an array of conflicting map items.

Count

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

HasChanges

Gets a value that determines whether the TopicMap has changed since it
was initialized (read from an XML file).

Item

Gets or sets the value associated with the specified key.

126

Keys

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

Values

(Inherited from System.Collections.Generic.Dictionary<object,MapItem>)

XmlSource

Gets or sets an System.Xml.XmlDocument value representing a TopicMap


created in authoring mode (so it consists of dynamic map items, static
map items aren't included), which is saved to an XML file.

Top

See Also
Reference
TopicMap Class
C1.Win.C1DynamicHelp Namespace

Conflicts Property
Gets an array of conflicting map items.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property Conflicts As Conflict()
C#
public Conflict[] Conflicts {get;}

Remarks
A conflict exists between two map items, one static and the other dynamic, when they refer to
the same UI element. In such a case, the precedence is with the dynamic map item, no error is
generated, the static map item is silently ignored.
Usually, there is no need to worry about these conflicts (mostly because static and dynamic
mappings are rarely mixed, usually either only static or only dynamic mappings are used), but in
case the programmer wants to know which items are in conflict with each other, that can be
done using this property.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
127

Reference
TopicMap Class
TopicMap Members

HasChanges Property
Gets a value that determines whether the TopicMap has changed since it was initialized (read
from an XML file).

Syntax
Visual Basic (Declaration)
Public ReadOnly Property HasChanges As Boolean
C#
public bool HasChanges {get;}

Remarks
This property is typically used in authoring mode, to check whether the TopicMap has changed
and should therefore be saved before the application closes.
It will return false if authoring mode is not used, unless the application changes the map
programmatically.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Item Property
The UI element of the value to get or set.
Gets or sets the value associated with the specified key.

Syntax
Visual Basic (Declaration)
Public Shadows Default Property Item( _

128

ByVal uiElement As Object _


) As MapItem
C#
public new MapItem this[
object uiElement
]; {get; set;}

Parameters
uiElement
The UI element of the value to get or set.

Property Value
The value associated with the specified key. If the specified key is not found, a get
operation throws a System.Collections.Generic.KeyNotFoundException, and a set
operation creates a new element with the specified key.

Exceptions
Exception

Description

System.Collections.Generic.KeyNotFoundException The property is retrieved and key does not


exist in the collection.
System.ArgumentNullException

key is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

XmlSource Property
Gets or sets an System.Xml.XmlDocument value representing a TopicMap created in authoring
mode (so it consists of dynamic map items, static map items aren't included), which is saved to
an XML file.

Syntax
129

Visual Basic (Declaration)


Public Property XmlSource As XmlDocument
C#
public XmlDocument XmlSource {get; set;}

Remarks
You can set this property instead of loading topic map from an XML file. For example, you can
choose to store the XML in application resources, create an XmlDocument at run time and
assign it to the XmlSource property.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

Events
%%scrap%%
" -->
For a list of all members of this type, see TopicMap members.

Public Events
Name

Description

TopicMapChanged Fires after changes were made in the topic map.


TopicMapSaved

Fires after the topic map is saved to an XML file.

Top

See Also
Reference
TopicMap Class
C1.Win.C1DynamicHelp Namespace

130

TopicMapChanged Event
Fires after changes were made in the topic map.

Syntax
Visual Basic (Declaration)
Public Event TopicMapChanged As EventHandler
C#
public event EventHandler TopicMapChanged

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
TopicMap Class
TopicMap Members

TopicMapSaved Event
Fires after the topic map is saved to an XML file.

Syntax
Visual Basic (Declaration)
Public Event TopicMapSaved As EventHandler
C#
public event EventHandler TopicMapSaved

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

131

TopicMap Class
TopicMap Members

UIElementInfo
This class contains information about a UI element: its Name and Parent.

Object Model

Syntax
Visual Basic (Declaration)
Public Class UIElementInfo
C#
public class UIElementInfo

Remarks
This class should be used only if you want to assign topics to UI elements in custom controls. If
you need to handle UI elements inside custom controls, you have to create your own
UIElementResolver object and override its virtual methods. Namely, when you override the
UIElementResolver.GetUIElementInfo method, you need to create a UIElementInfo object and
set its Name and Parent properties.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.UIElementInfo

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Members
C1.Win.C1DynamicHelp Namespace

Overview
This class contains information about a UI element: its Name and Parent.

Object Model
132

Syntax
Visual Basic (Declaration)
Public Class UIElementInfo
C#
public class UIElementInfo

Remarks
This class should be used only if you want to assign topics to UI elements in custom controls. If
you need to handle UI elements inside custom controls, you have to create your own
UIElementResolver object and override its virtual methods. Namely, when you override the
UIElementResolver.GetUIElementInfo method, you need to create a UIElementInfo object and
set its Name and Parent properties.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.UIElementInfo

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Members
C1.Win.C1DynamicHelp Namespace

Members
Properties

The following tables list the members exposed by UIElementInfo.

Public Constructors
Name

Description

UIElementInfo Constructor Overloaded.


Top

133

Public Properties
Name

Description

Name

Gets or sets the name of the UIElement. The name should be unique
inside the parent control.

Parent

Gets or sets the parent object of the UIElement.

UIElement

Gets the UI element for which this UIElementInfo object contains data.

Top

See Also
Reference
UIElementInfo Class
C1.Win.C1DynamicHelp Namespace

UIElementInfo Constructor
Overload List
Overload

Description

UIElementInfo Constructor(Object)

Initializes a new of instance of a


UIElementInfo

UIElementInfo Constructor(Object,String,Object) Initializes a new of instance of a


UIElementInfo

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Class
UIElementInfo Members

UIElementInfo Constructor(Object)
UI element for which this UIElementInfo object contains data.

134

Initializes a new of instance of a UIElementInfo

Syntax
Visual Basic (Declaration)
Public Function New( _
ByVal uiElement As Object _
)
C#
public UIElementInfo(
object uiElement
)

Parameters
uiElement
UI element for which this UIElementInfo object contains data.

Exceptions
Exception

Description

System.ArgumentNullException uiElement is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Class
UIElementInfo Members
Overload List

UIElementInfo Constructor(Object,String,Object)
UI element for which this UIElementInfo object contains data.
Name property for the specified uiElement
Parent property for the specified uiElement
Initializes a new of instance of a UIElementInfo

135

Syntax
Visual Basic (Declaration)
Public Function New( _
ByVal uiElement As Object, _
ByVal name As String, _
ByVal parent As Object _
)
C#
public UIElementInfo(
object uiElement,
string name,
object parent
)

Parameters
uiElement
UI element for which this UIElementInfo object contains data.
name
Name property for the specified uiElement
parent
Parent property for the specified uiElement

Exceptions
Exception

Description

System.ArgumentNullException uiElement is null.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2
(Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference

136

UIElementInfo Class
UIElementInfo Members
Overload List

Properties
%%scrap%%
" -->
For a list of all members of this type, see UIElementInfo members.

Public Properties
Name

Description

Name

Gets or sets the name of the UIElement. The name should be unique
inside the parent control.

Parent

Gets or sets the parent object of the UIElement.

UIElement

Gets the UI element for which this UIElementInfo object contains data.

Top

See Also
Reference
UIElementInfo Class
C1.Win.C1DynamicHelp Namespace

Name Property
Gets or sets the name of the UIElement. The name should be unique inside the parent control.

Syntax
Visual Basic (Declaration)
Public Property Name As String
C#
public string Name {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

137

See Also
Reference
UIElementInfo Class
UIElementInfo Members

Parent Property
Gets or sets the parent object of the UIElement.

Syntax
Visual Basic (Declaration)
Public Property Parent As Object
C#
public object Parent {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Class
UIElementInfo Members

UIElement Property
Gets the UI element for which this UIElementInfo object contains data.

Syntax
Visual Basic (Declaration)
Public ReadOnly Property UIElement As Object
C#
public object UIElement {get;}

Requirements

138

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
UIElementInfo Class
UIElementInfo Members

UIElementResolver
This class provides methods to find UI elements inside a control by name, coordinates, etc, and
other methods necessary for associating dynamic help to UI elements inside a control.

Object Model

Syntax
Visual Basic (Declaration)
Public Class UIElementResolver
C#
public class UIElementResolver

Remarks
A class derived from this class is necessary only if you are using custom controls that cannot be
handled by the C1DynamicHelp control automatically and then only if you need to associate
help topics with parts (UI elements) of those controls, not with the controls themselves.
You have no need to create objects of this type, it is sufficient to define a class derived from
UIElementResolver and override its virtual methods. These overridden methods should provide
necessary information about UI elements inside custom controls used in your application.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.UIElementResolver

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

139

See Also
Reference
UIElementResolver Members
C1.Win.C1DynamicHelp Namespace

Overview
This class provides methods to find UI elements inside a control by name, coordinates, etc, and
other methods necessary for associating dynamic help to UI elements inside a control.

Object Model

Syntax
Visual Basic (Declaration)
Public Class UIElementResolver
C#
public class UIElementResolver

Remarks
A class derived from this class is necessary only if you are using custom controls that cannot be
handled by the C1DynamicHelp control automatically and then only if you need to associate
help topics with parts (UI elements) of those controls, not with the controls themselves.
You have no need to create objects of this type, it is sufficient to define a class derived from
UIElementResolver and override its virtual methods. These overridden methods should provide
necessary information about UI elements inside custom controls used in your application.

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.UIElementResolver

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

140

UIElementResolver Members
C1.Win.C1DynamicHelp Namespace

Members
Methods

The following tables list the members exposed by UIElementResolver.

Public Methods
Name

Description

HandleUIElementEvent Simulates an event for a UI element.


Top

See Also
Reference
UIElementResolver Class
C1.Win.C1DynamicHelp Namespace

Methods
>
Name

Description

HandleUIElementEvent Simulates an event for a UI element.


Top

See Also
Reference
UIElementResolver Class
C1.Win.C1DynamicHelp Namespace

HandleUIElementEvent Method
A UI element for which an event occurred.
One of the UIElementEvents values, determining the type of the event (Enter or Leave).
Simulates an event for a UI element.

Syntax
Visual Basic (Declaration)
Public Sub HandleUIElementEvent( _

141

ByVal sender As Object, _


ByVal uiElementEvent As UIElementEvents _
)
C#
public void HandleUIElementEvent(
object sender,
UIElementEvents uiElementEvent
)

Parameters
sender
A UI element for which an event occurred.
uiElementEvent
One of the UIElementEvents values, determining the type of the event (Enter or Leave).

Remarks
You should call this method whenever one of the UIElementEvents (Enter/Leave)
occurs for a UI element that must be handled by your code, that is, the
C1DynamicHelp control cannot monitor this UI element for Enter/Leave events
automatically (because it does not have those events). By calling this method you
notify C1DynamicHelp that an event has occurred, so C1DynamicHelp can show the
topic associated with that UI element. Typical usage is to override the
ActivateUIElement method, subscribing there to some events that would help you
to detect the moments the focus enters/leaves the UI elements, and call
HandleUIElementEvent method from those event handlers. In the
HandleUIElementEvent call, the sender parameter is the UI element for which an
event occurred, and uiElementEvent is the type of the event (Enter or Leave).

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
UIElementResolver Class
UIElementResolver Members

142

Enumerations
DisplayTarget
Enumeration that specifies where a topic will be displayed.

Syntax
Visual Basic (Declaration)
Public Enum DisplayTarget
Inherits System.Enum
C#
public enum DisplayTarget : System.Enum

Members
Member

Description

ControlPanel

Specifies that a topic should be displayed in the C1DynamicHelp control.

ExternalWindow

Specifies that a topic should be displayed in an external window.

PanelAndWindow Specifies that a topic should be displayed both in the C1DynamicHelp


control and in an external help viewer window.

Remarks
This enumeration is used in C1DynamicHelp.ShowTopicForActiveControl, which is typically used
when a user presses the F1 key to get help. It allows to show a topic in the C1DynamicHelp
control, in an external window or both.

Inheritance Hierarchy
System.Object
System.ValueType
System.Enum
C1.Win.C1DynamicHelp.DisplayTarget

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

143

See Also
Reference
C1.Win.C1DynamicHelp Namespace

HelpTab
Enumeration specifying the part/element of the help file to display.

Syntax
Visual Basic (Declaration)
Public Enum HelpTab
Inherits System.Enum
C#
public enum HelpTab : System.Enum

Members
Member

Description

Find

The help file opens on the search page.

Index

The help file opens on the index.

TableOfContents The help file opens on the table of contents.


Topic

The help file opens on a specified topic.

Remarks
It is used by the C1DynamicHelp.ShowExternalHelp method.

Inheritance Hierarchy
System.Object
System.ValueType
System.Enum
C1.Win.C1DynamicHelp.HelpTab

Requirements

144

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1.Win.C1DynamicHelp Namespace

HelpTopicTrigger
Enumeration that specifies user actions that cause a HelpTopic to be displayed.

Syntax
Visual Basic (Declaration)
Public Enum HelpTopicTrigger
Inherits System.Enum
C#
public enum HelpTopicTrigger : System.Enum

Members
Member

Description

Enter

Show topic when a UI element gets the focus.

MouseEnter

Show help topic when the mouse hovers over a UI element.

None

Show topic programmatically, not by events.

Remarks
You can use combinations of this enumeration to show topics both on Enter and MouseHover
events.

Inheritance Hierarchy
System.Object
System.ValueType
System.Enum
C1.Win.C1DynamicHelp.HelpTopicTrigger

Requirements

145

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1.Win.C1DynamicHelp Namespace

MapItemType
Enumeration that specifies topic map item type.

Syntax
Visual Basic (Declaration)
Public Enum MapItemType
Inherits System.Enum
C#
public enum MapItemType : System.Enum

Members
Member

Description

Dynamic

Indicates map items created in authoring mode, saved to an XML file.

Static

Indicates map items created at design time, persisted in form code.

Remarks
Map items created at design time have the MapItemType.Static type, they are stored in the
form's code and cannot be saved to an XML file. Map items created in authoring mode have the
MapItemType.Dynamic type, they are saved to the XML file when the map is persisted. If you
create map items programmatically, you can choose any of these two types.

Inheritance Hierarchy
System.Object
System.ValueType
System.Enum
C1.Win.C1DynamicHelp.MapItemType

Requirements

146

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1.Win.C1DynamicHelp Namespace

UIElementEvents
Enumeration that specifies which of the monitored events occurred for a UI element.

Syntax
Visual Basic (Declaration)
Public Enum UIElementEvents
Inherits System.Enum
C#
public enum UIElementEvents : System.Enum

Members
Member

Description

Enter

UI element received focus.

Leave

UI element lost focus.

Remarks
It is used only in the UIElementResolver.HandleUIElementEvent method to specify the type of an
event. You need this enumeration only if you use custom controls and want to associate topics
with UI elements inside them.

Inheritance Hierarchy
System.Object
System.ValueType
System.Enum
C1.Win.C1DynamicHelp.UIElementEvents

Requirements

147

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
C1.Win.C1DynamicHelp Namespace

Delegates
HelpTopicEventHandler
The source of the event.
A TopicEventArgs that contains the event data.
Represents a method that will handle the C1DynamicHelp.CurrentTopicChanging event of a
C1DynamicHelp.

Syntax
Visual Basic (Declaration)
Public Delegate Sub HelpTopicEventHandler( _
ByVal sender As Object, _
ByVal e As TopicEventArgs _
)
C#
public delegate void HelpTopicEventHandler(
object sender,
TopicEventArgs e
)

Parameters
sender
The source of the event.
e
A TopicEventArgs that contains the event data.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

148

See Also
Reference
HelpTopicEventHandler Members
C1.Win.C1DynamicHelp Namespace

C1.Win.C1DynamicHelp.Providers Namespace
Overview
Classes
Class

Description

ChmProvider

The class providing the IHelpProvider functionality for HTML Help (.chm
files).

NetHelpProvider The class providing the IHelpProvider functionality for ComponentOne


NetHelp.

Interfaces
Interface

Description

IHelpProvider

The interface that needs to be implemented by a help provider class.

See Also
Reference
C1.Win.C1DynamicHelp.4 Assembly

Classes
ChmProvider
The class providing the IHelpProvider functionality for HTML Help (.chm files).

Object Model

Syntax

149

Visual Basic (Declaration)


Public Class ChmProvider
Implements IHelpProvider
C#
public class ChmProvider : IHelpProvider

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Providers.ChmProvider

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Overview
The class providing the IHelpProvider functionality for HTML Help (.chm files).

Object Model

Syntax
Visual Basic (Declaration)
Public Class ChmProvider
Implements IHelpProvider
C#
public class ChmProvider : IHelpProvider

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Providers.ChmProvider

150

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Members
Properties Methods

The following tables list the members exposed by ChmProvider.

Public Constructors
Name

Description

ChmProvider Constructor
Top

Public Properties
Name

Description

Source

Gets or sets the help file.

Top

Public Methods
Name

Description

CorrectUrl

Checks whether the URL is in correct format and corrects it if necessary.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs


(contains only topics that have context ids).

GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

151

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all


topics).

ShowExternalHelp Overloaded. Show help navigation (in a separate window).


Top

See Also
Reference
ChmProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

ChmProvider Constructor
Syntax
Visual Basic (Declaration)
Public Function New()
C#
public ChmProvider()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

Methods
>
Name

Description

CorrectUrl

Checks whether the URL is in correct format and corrects it if necessary.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs (contains

152

only topics that have context ids).


GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all


topics).

ShowExternalHelp Overloaded. Show help navigation (in a separate window).


Top

See Also
Reference
ChmProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

CorrectUrl Method
URL to be checked and corrected
Checks whether the URL is in correct format and corrects it if necessary.

Syntax
Visual Basic (Declaration)
Public Function CorrectUrl( _
ByVal url As String _
) As String
C#
public string CorrectUrl(
string url
)

Parameters
url
URL to be checked and corrected

Return Value
A corrected URL if some changes were made, otherwise the initial URL value

Remarks

153

Clicking some links in a *.chm file can lead to losing the path specified in the Source
property.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

GetCtxtIdMap Method
Returns a dictionary of help topics indexed by their context IDs (contains only topics that have
context ids).

Syntax
Visual Basic (Declaration)
Public Function GetCtxtIdMap() As Dictionary(Of Integer,HelpTopic)
C#
public Dictionary<int,HelpTopic> GetCtxtIdMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

GetFullUrl Method
Returns a URL in a specific for the help provider format that can be displayed by the
C1DynamicHelp control.

Syntax
Visual Basic (Declaration)

154

Public Function GetFullUrl( _


ByVal url As String _
) As String
C#
public string GetFullUrl(
string url
)

Parameters
url

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

GetTopics Method
Returns a hierarchical list of topics in the help file.

Syntax
Visual Basic (Declaration)
Public Function GetTopics() As HelpTopicList
C#
public HelpTopicList GetTopics()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

155

ChmProvider Class
ChmProvider Members

GetUrlMap Method
Returns a dictionary of help topics indexed by their URLs (contains all topics).

Syntax
Visual Basic (Declaration)
Public Function GetUrlMap() As Dictionary(Of String,HelpTopic)
C#
public Dictionary<string,HelpTopic> GetUrlMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

ShowExternalHelp Method
Show help navigation (in a separate window).

Overload List
Overload

Description

ShowExternalHelp(HelpTab)

Show help navigation (in a separate window).

ShowExternalHelp(HelpTab,Object) Show help navigation (in a separate window).

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference

156

ChmProvider Class
ChmProvider Members

ShowExternalHelp(HelpTab) Method
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
Show help navigation (in a separate window).

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab _
)
C#
public void ShowExternalHelp(
HelpTab tab
)

Parameters
tab
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members
Overload List

ShowExternalHelp(HelpTab,Object) Method
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
Topic identifier
Show help navigation (in a separate window).

157

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab, _
ByVal parameter As Object _
)
C#
public void ShowExternalHelp(
HelpTab tab,
object parameter
)

Parameters
tab
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
parameter
Topic identifier

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members
Overload List

Properties
%%scrap%%
" -->
For a list of all members of this type, see ChmProvider members.

Public Properties

158

Name

Description

Source

Gets or sets the help file.

Top

See Also
Reference
ChmProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

Source Property
Gets or sets the help file.

Syntax
Visual Basic (Declaration)
Public Property Source As String
C#
public string Source {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
ChmProvider Class
ChmProvider Members

NetHelpProvider
The class providing the IHelpProvider functionality for ComponentOne NetHelp.

Object Model

Syntax

159

Visual Basic (Declaration)


Public Class NetHelpProvider
Implements IHelpProvider
C#
public class NetHelpProvider : IHelpProvider

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Providers.NetHelpProvider

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Overview
The class providing the IHelpProvider functionality for ComponentOne NetHelp.

Object Model

Syntax
Visual Basic (Declaration)
Public Class NetHelpProvider
Implements IHelpProvider
C#
public class NetHelpProvider : IHelpProvider

Inheritance Hierarchy
System.Object
C1.Win.C1DynamicHelp.Providers.NetHelpProvider

160

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Members
Properties Methods

The following tables list the members exposed by NetHelpProvider.

Public Constructors
Name

Description

NetHelpProvider Constructor
Top

Public Properties
Name

Description

Source

Gets or sets the help file.

Top

Public Methods
Name

Description

CorrectUrl

This method is not meaningful for the NetHelpProvider. It is used only


to implement the IHelpProvider interface.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs


(contains only topics that have context ids).

GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

161

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all


topics).

ShowExternalHelp Overloaded. Show help navigation (in a separate window).


Top

See Also
Reference
NetHelpProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

NetHelpProvider Constructor
Syntax
Visual Basic (Declaration)
Public Function New()
C#
public NetHelpProvider()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

Methods
%%scrap%%
" -->
For a list of all members of this type, see NetHelpProvider members.

Public Methods

162

Name

Description

CorrectUrl

This method is not meaningful for the NetHelpProvider. It is used only


to implement the IHelpProvider interface.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs


(contains only topics that have context ids).

GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all


topics).

ShowExternalHelp Overloaded. Show help navigation (in a separate window).


Top

See Also
Reference
NetHelpProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

CorrectUrl Method
Url to be checked and corrected
This method is not meaningful for the NetHelpProvider. It is used only to implement the
IHelpProvider interface.

Syntax
Visual Basic (Declaration)
Public Function CorrectUrl( _
ByVal url As String _
) As String
C#
public string CorrectUrl(

163

string url
)

Parameters
url
Url to be checked and corrected

Return Value
Always the initial url

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

GetCtxtIdMap Method
Returns a dictionary of help topics indexed by their context IDs (contains only topics that have
context ids).

Syntax
Visual Basic (Declaration)
Public Function GetCtxtIdMap() As Dictionary(Of Integer,HelpTopic)
C#
public Dictionary<int,HelpTopic> GetCtxtIdMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

164

GetFullUrl Method
Returns a URL in a specific for the help provider format that can be displayed by the
C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Public Function GetFullUrl( _
ByVal url As String _
) As String
C#
public string GetFullUrl(
string url
)

Parameters
url

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

GetTopics Method
Returns a hierarchical list of topics in the help file.

Syntax
Visual Basic (Declaration)
Public Function GetTopics() As HelpTopicList
C#
public HelpTopicList GetTopics()

Requirements

165

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

GetUrlMap Method
Returns a dictionary of help topics indexed by their URLs (contains all topics).

Syntax
Visual Basic (Declaration)
Public Function GetUrlMap() As Dictionary(Of String,HelpTopic)
C#
public Dictionary<string,HelpTopic> GetUrlMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

ShowExternalHelp Method
Show help navigation (in a separate window).

Overload List
Overload

Description

ShowExternalHelp(HelpTab)

Show help navigation (in a separate window).

ShowExternalHelp(HelpTab,Object) Show help navigation (in a separate window).

Requirements
166

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

ShowExternalHelp(HelpTab) Method
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
Show help navigation (in a separate window).

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab _
)
C#
public void ShowExternalHelp(
HelpTab tab
)

Parameters
tab
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members
Overload List

167

ShowExternalHelp(HelpTab,Object) Method
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
Topic identifier
Show help navigation (in a separate window).

Syntax
Visual Basic (Declaration)
Public Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab, _
ByVal parameter As Object _
)
C#
public void ShowExternalHelp(
HelpTab tab,
object parameter
)

Parameters
tab
Initial help page to display, typically HelpTab.Find, HelpTab.Index, or
HelpTab.TableOfContents.
parameter
Topic identifier

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members
Overload List

Properties
>

168

Name
Source

Description
Gets or sets the help file.

Top

See Also
Reference
NetHelpProvider Class
C1.Win.C1DynamicHelp.Providers Namespace

Source Property
Gets or sets the help file.

Syntax
Visual Basic (Declaration)
Public Property Source As String
C#
public string Source {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
NetHelpProvider Class
NetHelpProvider Members

Interfaces
IHelpProvider
The interface that needs to be implemented by a help provider class.

Object Model

Syntax

169

Visual Basic (Declaration)


Public Interface IHelpProvider
C#
public interface IHelpProvider

Remarks
You need to know this interface only if you want to create your own custom help provider (an
advanced feature). A help provider can read data from a help source and provides methods to
get help topics, to get context IDs, to open help in an external window, to get a topic URL that
can be displayed by the C1DynamicHelp control, etc. There are two built-in help providers in
the C1DynamicHelp: ChmProvider and NetHelpProvider which are used automatically when the
HelpSource property points to a .chm or a .htm/html file, correspondingly. If you want to use
another help source type (for example, MS Help 2.0) you can do it by creating your own help
provider class implementing this interface.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Overview
The interface that needs to be implemented by a help provider class.

Object Model

Syntax
Visual Basic (Declaration)
Public Interface IHelpProvider
C#
public interface IHelpProvider

170

Remarks
You need to know this interface only if you want to create your own custom help provider (an
advanced feature). A help provider can read data from a help source and provides methods to
get help topics, to get context IDs, to open help in an external window, to get a topic URL that
can be displayed by the C1DynamicHelp control, etc. There are two built-in help providers in
the C1DynamicHelp: ChmProvider and NetHelpProvider which are used automatically when the
HelpSource property points to a .chm or a .htm/html file, correspondingly. If you want to use
another help source type (for example, MS Help 2.0) you can do it by creating your own help
provider class implementing this interface.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Members
C1.Win.C1DynamicHelp.Providers Namespace

Members
Properties Methods

The following tables list the members exposed by IHelpProvider.

Public Properties
Name

Description

Source

Gets or sets the help file.

Top

Public Methods
Name

Description

CorrectUrl

Checks whether the URL is in correct format and corrects it if necessary.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs


(contains only topics that have context ids).

171

GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all


topics).

ShowExternalHelp Overloaded. Displays the contents of the help file in an external help
viewer window instead of in the C1DynamicHelp panel.
Top

See Also
Reference
IHelpProvider Interface
C1.Win.C1DynamicHelp.Providers Namespace

Methods
%%scrap%%
" -->
For a list of all members of this type, see IHelpProvider members.

Public Methods
Name

Description

CorrectUrl

Checks whether the URL is in correct format and corrects it if necessary.

GetCtxtIdMap

Returns a dictionary of help topics indexed by their context IDs


(contains only topics that have context ids).

GetFullUrl

Returns a URL in a specific for the help provider format that can be
displayed by the C1DynamicHelp control.

GetTopics

Returns a hierarchical list of topics in the help file.

GetUrlMap

Returns a dictionary of help topics indexed by their URLs (contains all

172

topics).
ShowExternalHelp Overloaded. Displays the contents of the help file in an external help
viewer window instead of in the C1DynamicHelp panel.
Top

See Also
Reference
IHelpProvider Interface
C1.Win.C1DynamicHelp.Providers Namespace

CorrectUrl Method
URL to be checked and corrected
Checks whether the URL is in correct format and corrects it if necessary.

Syntax
Visual Basic (Declaration)
Function CorrectUrl( _
ByVal url As String _
) As String
C#
string CorrectUrl(
string url
)

Parameters
url
URL to be checked and corrected

Return Value
A corrected URL if some changes were made, otherwise the initial URL value

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
173

Reference
IHelpProvider Interface
IHelpProvider Members

GetCtxtIdMap Method
Returns a dictionary of help topics indexed by their context IDs (contains only topics that have
context ids).

Syntax
Visual Basic (Declaration)
Function GetCtxtIdMap() As Dictionary(Of Integer,HelpTopic)
C#
Dictionary<int,HelpTopic> GetCtxtIdMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

GetFullUrl Method
Returns a URL in a specific for the help provider format that can be displayed by the
C1DynamicHelp control.

Syntax
Visual Basic (Declaration)
Function GetFullUrl( _
ByVal url As String _
) As String
C#
string GetFullUrl(
string url
)

174

Parameters
url

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

GetTopics Method
Returns a hierarchical list of topics in the help file.

Syntax
Visual Basic (Declaration)
Function GetTopics() As HelpTopicList
C#
HelpTopicList GetTopics()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

GetUrlMap Method
Returns a dictionary of help topics indexed by their URLs (contains all topics).

Syntax
Visual Basic (Declaration)

175

Function GetUrlMap() As Dictionary(Of String,HelpTopic)


C#
Dictionary<string,HelpTopic> GetUrlMap()

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

ShowExternalHelp Method
Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Overload List
Overload

Description

ShowExternalHelp(HelpTab)

Displays the contents of the help file in an external help


viewer window instead of in the C1DynamicHelp panel.

ShowExternalHelp(HelpTab,Object) Displays the contents of the help file in an external help


viewer window instead of in the C1DynamicHelp panel.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

ShowExternalHelp(HelpTab) Method
One of the C1.Win.C1DynamicHelp.HelpTab values.

176

Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Syntax
Visual Basic (Declaration)
Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab _
)
C#
void ShowExternalHelp(
HelpTab tab
)

Parameters
tab
One of the C1.Win.C1DynamicHelp.HelpTab values.

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows
Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported
with SP1 or later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members
Overload List

ShowExternalHelp(HelpTab,Object) Method
One of the C1.Win.C1DynamicHelp.HelpTab values.
Displays the contents of the help file in an external help viewer window instead of in the
C1DynamicHelp panel.

Syntax
Visual Basic (Declaration)
Overloads Sub ShowExternalHelp( _
ByVal tab As HelpTab, _
ByVal parameter As Object _

177

)
C#
void ShowExternalHelp(
HelpTab tab,
object parameter
)

Parameters
tab
One of the C1.Win.C1DynamicHelp.HelpTab values.
parameter

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3,
Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server
Core supported with SP1 or later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members
Overload List

Properties
>
Name
Source

Description
Gets or sets the help file.

Top

See Also
Reference
IHelpProvider Interface
C1.Win.C1DynamicHelp.Providers Namespace

Source Property
Gets or sets the help file.

Syntax

178

Visual Basic (Declaration)


Property Source As String
C#
string Source {get; set;}

Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server
2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or
later), Windows Server 2003 SP2

See Also
Reference
IHelpProvider Interface
IHelpProvider Members

179

You might also like