Custom Form Forcing Save

  • Thread starter Thread starter Cass
  • Start date Start date
C

Cass

On my form I have the following code:

Function Item_Write()

If Item.UserProperties.Find("Utility") <> "" Then
If Item.UserProperties.Find("CityState") <> "" Then

Item.FileAs = Item.UserProperties.Find("Utility") & vbcrlf & _
Item.UserProperties.Find("CityState")

Else
Item.FileAs=Item.UserProperties.Find("Utility")
End If
Else
Item.FileAS=Item.UserProperties.Find("CityState")
End If
End Function


When I try to use the default Contacts button on the custom form it
gives me this "The item must be saved. Would you lilke to save it
now?"

Also, the form is being named "()" in the title bar.

Anybody know why it is doing this?
 
When I try to use the default Contacts button on the custom form it
gives me this "The item must be saved. Would you lilke to save it
now?"

This sounds like normal behavior. A contact must be saved before you can link it to other contacts.
Also, the form is being named "()" in the title bar.

Do you have a formula on the FileAs field, in addition to your code?
 
What are the values of Utility and CityState when that happens? Feel free to put in a MsgBox statement for troubleshooting.

I don't think your code provides a solution for the case where both those properties are blank.
 
Back
Top