Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.

Sample Definition (.HxE) File 

Specifies the sample files to be included with a compiled Help (.HxS) file. You can use samples to provide files, such as code examples or entire Visual Studio projects, to users. Sample files can either be compiled, or compressed, into a Help file, or included in an uncompressed form.


The following example shows the basic structure of a sample definition file.


The file consists of tags, each of which contains one or more attributes.

Choose an attribute to see its corresponding topic.

Comments indicate which attributes are required.

Where applicable, defined choices are displayed in parentheses.

All attribute values must be enclosed in quotation marks.

As with all XML documents, the tags and attributes in this file are case-sensitive.

<?xml version="1.0"?>

<!DOCTYPE HelpSamples SYSTEM "MS-Help://Hx/Resources/HelpSamples.dtd">


   Id Attribute = ""

  DTDVersion Attribute = "1.0" <!-- Required -->

   FileVersion Attribute = ""


<Sample <!-- Can appear 0 or more times -->

   SampleId Attribute = ""

   Id Attribute = ""

   SFLName Attribute = "" <!-- Required -->

   Compressed Attribute = (Yes | No)

   SourceDir Attribute = "" <!-- Required -->

   DistribDir Attribute = ""

   CopyDestDir Attribute = ""

   LoadString Attribute = ""

   ProjFileExt Attribute = ""


   <ExcludeExt <!-- Can appear 0 or more times -->

      Id Attribute = ""

      Extension Attribute = "" <!-- Required -->


   <IncludeDir <!-- Can appear 0 or more times -->

      Id Attribute = ""

      Directory Attribute = "" <!-- Required -->


   <ExcludeDir <!-- Can appear 0 or more times -->

      Id = ""

      Directory = "" <!-- Required -->


   <ToolData <!-- Can appear 0 or more times -->

      Name Attribute = "" <!-- Required -->

      Value Attribute = "" <!-- Required -->





The respective values assigned to the Title and Id attributes should not exceed 2000 characters. If this limit is exceeded, the value is truncated. The compiler does not issue an error or warning at this time.


If the value for the SFLName attribute is not unique for each sample, sample data will be overwritten. For example, if sample A and sample B have the same SFLName value, the data for sample B will overwrite that of sample A. This applies to uncompressed samples.

See Also

Community Additions

© 2015 Microsoft