Program Help for .NET

.NET basics

Supports all forms of RoboHelp Server with .NET development:

  • Creates web services, WebForms, and WinForms.

  • Provides comprehensive support for .NET Framework.

  • Operates as a self-contained .NET web service.

  • Provides APIs to support Help development in Visual C .NET, C# .NET, Visual Basic .NET, and ASP .NET.

  • Ensures that existing context-sensitive Help supports .NET requirements.

RoboHelp Server with .NET is designed to create applications for desktops, intranets, or the Internet and to support the development of these applications.

Create server-based Help within the .NET environment and generate real-time analysis of end-user activity in a Help system. Use with Visual C .NET, ASP .NET, Visual Basic .NET, or C# .NET to integrate Help systems.

Context-sensitive Help support files for .NET

Support files for programming context-sensitive Help allow you to import code and enter variables instead of writing the code. The context-sensitive Help API for .NET supports Visual C++ .NET, ASP .NET, Visual Basic .NET, and C# .NET.

The API shares parameters with HTML Help and WinHelp. Custom windows are supported. Context-sensitive Help works without any modifications.

Import file for the corresponding language from the respective folders at:

C:\Program Files\Adobe\Adobe RoboHelp 8\CSH API

C# .NET

C# .NET is an object-oriented language that enables C and C++ programmers to transition to the new .NET environment while providing integration with existing applications. Components can be converted into XML and run using any language on any operating system.

ASP .NET

ASP .NET is part of the .NET Framework for building web applications and XML web services. ASP .NET pages use a compiled, event-driven programming model to generate markup such as HTML, WML, or XML. It allows the separation of application logic and user interface. You can use any .NET language, such as Visual Basic .NET or C# .NET, to create ASP .NET pages and AS P.NET XML web services files containing server-side logic.

Make a Help call

Use the context-sensitive Help code samples that Adobe provides.

Make sure that context-sensitive Help function calls specify the online Help in the individual calls to RH_Showhelp. When a remote Help call is made, the online version of the Help system appears. If connecting to the Internet is not possible, offline Help appears.

Call context-sensitive Help for WebHelp or FlashHelp from C# .NET

  1. Include the RoboHelp_CSH.cs file in the project.

  2. Call the RH_ShowLocalHelp (hParent, strtHelpURL, strWndName, nCommand, nData)function.

    Parameter

    Data Type

    Description

    hParent

    Object

    Handle of the parent window.

    strHelpURL

    String

    Help source for WebHelp; specifies the path to the project start page.

    strWndName

    String

    Name of the window to be opened.

    nCommand

    Int

    Class constants.

    OptionConstants.CSH_DISPLAY_CONTEXT
    Opens the topic associated with the map ID in the nData parameter

    OptionConstants.CSH_DISPLAY_TOC
    Displays the Contents pane and the default topic

    OptionConstants.CSH_DISPLAY_INDEX
    Displays the Index pane and the default topic

    OptionConstants.CSH_DISPLAY_SEARCH
    Displays the Search pane and the default topic

    nData

    Int

    Displays the map ID of the topic. To obtain the map ID, you can export the map file for a programming language using OptionConstants.CSH_DISPLAY_CONTEXT in nCommand.

Call context-sensitive Help for WebHelp Pro or FlashHelp Pro from C# .NET

  1. Open VisualStudio.

  2. Do one of the following:

    • Select File > New > Project.

    • Open a C# .NET project.

  3. Add a button named Help.

  4. Navigate to the context-sensitive Help supporting files in C:\Program Files\[RoboHelp Install Folder]\CSH API\CS.NET.

  5. Copy the RoboHelp_CSH.cs file.

  6. Paste the files to the C# .NET project.

  7. Right-click the Reference folder. Select Add Reference.

  8. Select .Net tab > System.Web.Services.Dll.

  9. Click OK.

  10. Right-click the Reference folder. Select Add Reference.

  11. Select

    c:\windows\system32\msxml2.dll
  12. Select OK.

  13. Double-click the Help button.

  14. Copy C# .NET context-sensitive Help example code and paste into the code.

  15. Add using RoboHelpAPI to the top of the document.

  16. To test, compile, and run the project, select the Help button.

Call context-sensitive Help for WebHelp or FlashHelp from ASP .NET

  1. Include the RoboHelp_CSH.cs file in the project.

  2. Call the RH_ShowLocalHelp (hParent, strtHelpURL, strWndName, nCommand, nData)function.

    Parameter

    Data Type

    Description

    hParent

    Object

    Handle of the parent window.

    strHelpURL

    String

    Help source for WebHelp; specifies the path to the project start page.

    strWndName

    String

    Name of the window to be opened.

    nCommand

    Int

    Class constants.

    OptionConstants.CSH_DISPLAY_CONTEXT
    Opens the topic associated with the map ID in the nData parameter

    OptionConstants.CSH_DISPLAY_TOC
    Displays the Contents pane and the default topic

    OptionConstants.CSH_DISPLAY_INDEX
    Displays the Index pane and the default topic

    OptionConstants.CSH_DISPLAY_SEARCH
    Displays the Search pane and the default topic

    nData

    Int

    Displays the map ID of the topic. To obtain the map ID, you can export the map file for a programming language using OptionConstants.CSH_DISPLAY_CONTEXT in nCommand.

Call context-sensitive Help for WebHelp Pro or FlashHelp Pro from ASP .NET

  1. Open VisualStudio .NET.

  2. Do one of the following:

    • Select File > New > Project.

    • Open an ASP.NET project.

  3. Navigate to the context-sensitive Help supporting files in C:\Program Files\[RoboHelp Install Folder]\CSH API\ASP.NET.

  4. Copy the RoboHelp_CSH.cs file.

  5. Paste the supporting files to the ASP.NET project.

  6. Right-click the Reference folder. Select Add Reference.

  7. Select .Net tab > System.Web.Services.Dll.

  8. Click OK.

  9. Add a button in the application.

  10. Double-click the button.

  11. Copy the ASP.NET context-sensitive Help example code. Paste it into the code.

  12. In the code, add using RoboHelpAPI.

  13. To test, compile and run the project. Select the Help button.

Call context-sensitive Help for WebHelp or FlashHelp from Visual Basic .NET

  1. Include the RoboHelp_CSH.vb file in the project.

  2. Call the RH_ShowLocalHelp (hParent, strtHelpURL, strWndName, nCommand, nData)function.

    Parameter

    Data Type

    Description

    hParent

    Object

    Handle of the parent window.

    strHelpURL

    String

    Help source for WebHelp; specifies the path to the project start page.

    strWndName

    String

    Name of the window to be opened.

    nCommand

    Int

    Class constants.

    CSH_DISPLAY_CONTEXT
    Opens the topic associated with the map ID in the nData parameter

    CSH_DISPLAY_TOC
    Displays the Contents pane and the default topic

    CSH_DISPLAY_INDEX
    Displays the Index pane and the default topic

    CSH_DISPLAY_SEARCH
    Displays the Search pane and the default topic

    nData

    Int

    Displays the map ID of the topic. To obtain the map ID, you can export the map file for a programming language using CSH_DISPLAY_CONTEXT in nCommand.

Call context-sensitive Help for WebHelp Pro or FlashHelp Pro from Visual Basic .NET

  1. Open VisualStudio.NET.

  2. Do one of the following:

    • Select File > New > Project.

    • Open a Visual Basic .NET project.

  3. Navigate to the context-sensitive Help files for ASP .NET in C:\Program Files\[RoboHelp Install Folder]\CSH API\VB.NET.

  4. Copy the RoboHelp_CSH.vb file.

  5. Paste the supporting files to the ASP .NET project.

  6. Right-click the Reference folder. Select Add Reference.

  7. Select .Net tab > System.Web.Services.Dll.

  8. Click OK.

  9. Right-click the Reference. Select Add Reference.

  10. Select:

    msxml2.dll
  11. Select OK.

  12. Add a button in the application.

  13. Double-click the button.

  14. Copy the Visual Basic .NET context-sensitive Help example code and paste it into the code.

  15. To test, compile and run the project. Select the Help button.

Locate the RoboHelp Server with .NET samples

  1. Select Start > Programs > Robohelp Office Pro For .Net Development Kit.

  2. Select the sample for the application language.

    Name

    Language

    RoboHelp Server CSH.NET VC Sample

    Visual C++ .NET

    RoboHelp CSH.NET VB Sample

    Visual Basic .NET

    RoboHelp CSH.NET C# Sample

    C# .NET

Specify the URL (WebHelp Pro)

  1. In code samples, find the string with the name:

    m_strServer
  2. Assign the server address to m_strServer:

    http://server.com/robohelp/rest
  3. Specify a project name.

    m_strProject = P1
  4. Specify the window name in the variable m_strParamValue.

Note: STRPRIMARY specifies the primary Help system and STRBACKUP specifies local Help. For Visual Basic .NET, Visual C++ .NET, and C# .NET the application is on the client, allowing both online and offline Help systems. For ASP .NET, all information is on a Web server. Specify a WebHelp Pro online Help system as a primary Help system and a WebHelp online Help system as a backup.

Web services provided in RoboHelp Server with .NET

RoboHelp Server provides the following two services using the REST web services.

Robowindow
Requests the server to get the window properties and context Help URL. See code details.

Search
Performs the sentence search and returns results. See code details.

// Ethnio survey code removed