View Single Post
  #6 (permalink)  
Old 05-13-2008, 04:58 PM
Erel's Avatar
Erel Erel is offline
Administrator
 
Join Date: Apr 2007
Posts: 3,185
Default

Yes, IsNull will not help here.
Contact.WebPage will only work properly if the contact's webpage field is a valid URL.
The "http://" prefix is also required.
This is a limitation of the underlying .Net CF method.
The only workaround I can think of is to catch this error:
Code:
        spouse                = contact.Spouse
        suffix                = contact.Suffix
        title                = contact.Title
        website                = GetWebsite
        table1.AddRow(... )
    Next
End Sub

Sub GetWebsite
    ErrorLabel(errGetWebsite)
    Return contact.WebPage
errGetWebsite:
    Return ""
End Sub
Reply With Quote