Help File - Opens on Find tab not Contents tab 
Author Message
 Help File - Opens on Find tab not Contents tab

I have written a Help file using MS Help Workshop and it runs OK except
that every time I open Help the Help Contents comes up with the Find tab
on top. How can I change this so that the Contents tab comes up on top
when I open the Help file?
--

David Hewitt Pottery ,
7 Fairfield Road, Caerleon, Newport,
South Wales, NP18 3DQ, UK.      Tel:- +44 (0) 1633 420647
FAX:- +44 (0) 870 1617274
Web site http://www.*-*-*.com/


Wed, 05 Jan 2005 23:44:30 GMT  
 Help File - Opens on Find tab not Contents tab
Put this in your General declarations:

Private Declare Function OSWinHelp% Lib "user32"
Alias "WinHelpA" _
   (ByVal hWnd&, ByVal HelpFile$, ByVal wCommand%, dwData
As Any)

Then in your program:
'******************
'* Show Help File *
'******************
Dim nRet As Integer

If Len(App.HelpFile) = 0 Then
   MsgBox "Unable to display Help Search. There is no Help
associated with this project.", vbInformation, Me.Caption
Else
   On Error Resume Next
   nRet = OSWinHelp(Me.hWnd, App.HelpFile, 3, 0)
   If Err Then
      MsgBox Err.Description
   End If
End If

HTH,
Rob

Quote:
>-----Original Message-----
>I have written a Help file using MS Help Workshop and it
runs OK except
>that every time I open Help the Help Contents comes up
with the Find tab
>on top. How can I change this so that the Contents tab
comes up on top
>when I open the Help file?
>--

>David Hewitt Pottery ,
>7 Fairfield Road, Caerleon, Newport,
>South Wales, NP18 3DQ, UK.      Tel:- +44 (0) 1633 420647
>FAX:- +44 (0) 870 1617274
>Web site http://www.dhpot.demon.co.uk



Fri, 07 Jan 2005 23:18:46 GMT  
 Help File - Opens on Find tab not Contents tab
Rob,
Thanks for the detailed coding.
I suspect I have not interpreted it correctly as I couldn't get it to
work.
However, I have found some coding which does work for me. It is as
follows:-

CommonDialog1.CancelError = True
On Error GoTo ErrHandler
Commondialog1.HelpCommand = &HB
Commondialog1.HelpFile = "C:\MyFile.hlp"
CommonDialog1.ShowHelp

ErrHandler:
        Exit Sub

End Sub

I had previously had the HelpCommand = cdlHelpForceFile, but found in
the VB Help files that if I was compiling the Help file using MS Help
Workshop 4.0X, then I should change this to HelpCommand = &HB.

It made the difference that I was after.

Thanks again for your time and help

David



Quote:
>Put this in your General declarations:

>Private Declare Function OSWinHelp% Lib "user32"
>Alias "WinHelpA" _
>   (ByVal hWnd&, ByVal HelpFile$, ByVal wCommand%, dwData
>As Any)

>Then in your program:
>'******************
>'* Show Help File *
>'******************
>Dim nRet As Integer

>If Len(App.HelpFile) = 0 Then
>   MsgBox "Unable to display Help Search. There is no Help
>associated with this project.", vbInformation, Me.Caption
>Else
>   On Error Resume Next
>   nRet = OSWinHelp(Me.hWnd, App.HelpFile, 3, 0)
>   If Err Then
>      MsgBox Err.Description
>   End If
>End If

>HTH,
>Rob

>>-----Original Message-----
>>I have written a Help file using MS Help Workshop and it
>runs OK except
>>that every time I open Help the Help Contents comes up
>with the Find tab
>>on top. How can I change this so that the Contents tab
>comes up on top
>>when I open the Help file?
>>--

>>David Hewitt Pottery ,
>>7 Fairfield Road, Caerleon, Newport,
>>South Wales, NP18 3DQ, UK.      Tel:- +44 (0) 1633 420647
>>FAX:- +44 (0) 870 1617274
>>Web site http://www.dhpot.demon.co.uk

--

David Hewitt Pottery ,
7 Fairfield Road, Caerleon, Newport,
South Wales, NP18 3DQ, UK.      Tel:- +44 (0) 1633 420647
FAX:- +44 (0) 870 1617274
Web site http://www.dhpot.demon.co.uk


Sun, 09 Jan 2005 03:17:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. tab bars do not match tab page

2. Tab stop ranges not unique in tab panels!

3. Tabbing thru the tab control (not to be confused with tiptoeing thru the tullips)

4. open mdb file and create several tab delimited ascii files

5. Showing Help Contents tab from VB5

6. Displaying Help Contents Tab

7. Windows 95 Help Contents Tab

8. Displaying the Contents Tab in Win95 Help

9. Posting Only Help Contents Tab from VB5

10. Showing Help Contents tab from VB5

11. Opening a tab delimited text file as a worksheet

12. Open tab delimited text file

 

 
Powered by phpBB® Forum Software