g


Public Sub AddToRecentDocs(ByVal sFile As String)
   
   sFile = GetLongPath(sFile)
   If Len(sFile) &gt; 0 Then
      If (IsNt) Then
         SHAddToRecentDocs SHARD_PATHW, ByVal StrPtr(sFile)
      Else
         SHAddToRecentDocs SHARD_PATHA, ByVal sFile
      End If
      If Not (Err.LastDllError = 0) Then
         Select Case Err.LastDllError
         Case 1008
            ' already exists
         Case 6
            ' already exists
         Case Else
            ' error
            Err.Raise Err.L