Hide custom page?
From: John Riddle (JohnRiddle_at_discussions.microsoft.com)
Date: 06/28/04
- Next message: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Previous message: Sue Mosher [MVP-Outlook]: "Re: Organization forms"
- Next in thread: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Reply: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 28 Jun 2004 10:24:02 -0700
Hello,
I have a custom tab on a contact and based on whether a file exists in a shared directory, the custom page will be displayed. My problem is that if the page is not displayed for a contact, it doesn't show the page exactly like it is supposed to. However, if you close and re-open the contact (without first switching to a different contact in the folder view and switching back), then there's an error opening the contacts saying (Object required). My code that runs in the item_open event is pasted below:
Sub Item_Open()
Set myBrowser = Item.GetInspector.ModifiedFormPages("MS Word Resume").WebBrowser1
strResumePath = "\\wgny\wilson group shared\resumes\"
strResumeName = Item.FirstName & " " & Item.LastName & ".doc"
Set resumeFSO = CreateObject("Scripting.FileSystemObject")
If resumeFSO.FileExists(strResumePath & strResumeName) Then
strResumePath = strResumePath & strResumeName
ElseIf resumeFSO.FileExists(strResumePath & Item.FirstName & Item.LastName & ".doc") Then
strResumeName = Item.FirstName & Item.LastName & ".doc"
strResumePath = strResumePath & strResumeName
Else
on error resume next
Item.GetInspector.HideFormPage "MS Word Resume"
End If
End Sub
Does anyone know of a better way to accomplish this same thing?
John
- Next message: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Previous message: Sue Mosher [MVP-Outlook]: "Re: Organization forms"
- Next in thread: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Reply: Sue Mosher [MVP-Outlook]: "Re: Hide custom page?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|