Microsoft Access 2000


         

Public Function funCreateNewHelp()


Dim fs, s As String, hlp As String

On Error GoTo 999

Set fs = CreateObject("Scripting.FileSystemObject") '

s = fs.GetSpecialFolder(0) & "\hh.exe" ' hh.exe

If Dir(s) <> "" Then ' exe-

hlp = fs.GetFile(CurrentDb.Name).ParentFolder & "\.chm" '

If Dir(hlp) <> "" Then '

s = """" & s & """ -mapid " & 103 & " """ & hlp & """" '

Shell s, vbMaximizedFocus '

End If

End If

Exit Function '

999:

Err.Clear '