Opening HTML files

  • Thread starter Thread starter Nigel Findlater
  • Start date Start date
N

Nigel Findlater

Hallo,

I would like to make Help files in HTML. The only way I
found how to display these files is:

Dim pHelp As New ProcessStartInfo
pHelp.FileName = "explorer.exe"
pHelp.Arguments = "Help.htm"
pHelp.UseShellExecute = True
pHelp.WindowStyle = ProcessWindowStyle.Normal
Dim proc As Process = Process.Start(pHelp)

This works under Windows 2000, Windows ME but not under
Windows NT. Does anyone have a better approach?

Nigel...
 
* "Nigel Findlater said:
I would like to make Help files in HTML. The only way I
found how to display these files is:

Have a look at the 'HelpProvider' class.
 
Thanks Herfried,

I took a look at HelpProvider but as far as I can see
these provide help very much on a control by control
basis. I have a user manual written in Word that I like to
save as an HTML document and make this available..

Nigel...

Here are my notes from the HelpProvider, let me know if I
misunderstood how this works...

1. Drag and drop the Help Provider, Tool Tip and
ErrorProvider onto the form
2. Go to the control
3. HelpString on HelpProvider1 : Enter the name of the
product
4. ShowHelp on HelpProvider1: True
5. ToolTip on ToolTip1: The name of the product

To use the error provider
if txtProduct="" then ErrorProvider1.SetError
(txtProduct, "Enter a valid number in the range 1-100")
The result is a little explaination mark next to the
control with the text.
 
You can use the Microsoft Web Control (the IE web browser
ActiveX control) and add it to a form. This lets you
create a mini-browser that is hosted in a .Net form.
Unfortunately, there is not much documentation available
for doing this. You would need to add a reference to the
control to your project. On the COM tab of the add
reference dialog, choose "Microsoft Internet Controls".
Doing so should add the web browser control to your
toolbox. You should then be able to drop an instance of
the control onto a windows form. To make it display a
page, use the following C# code:

string startupURL = "www.microsoft.com";
System.Object nullObject = 0;
string str = "";
System.Object nullObjStr = str;
Cursor.Current = Cursors.WaitCursor;
axWebBrowser1.Navigate(startupURL, ref nullObject, ref
nullObjStr, ref nullObjStr, ref nullObjStr);
Cursor.Current = Cursors.Default;

Have fun...
 
Back
Top