Click or drag to resize

IScriptingEventsOnCurrentSaleCreated Method

Called when a new object is saved for the first time.

Namespace:  SuperOffice.COM.ScriptEvents
Assembly:  Scripting.Interop (in Scripting.Interop.dll) Version: 8.0.0.0
Syntax
void OnCurrentSaleCreated()
Examples

Description

This text may be copied to the notepad, and saved as a *.vbs file.

VB
sub oncurrentsalecreated
'we create a followup to call the customer two days after a sale is registered
      Set newAppnt1 = database.CreateAppointment
      newAppnt1.SetDefaults
      newAppnt1.Contact = Currentsale.Contact
      newAppnt1.Person = Currentsale.Person
      newAppnt1.task = database.GetListItemByName(67, "Phone-Out")
      newAppnt1.DoBy = DateAdd("d", 2, Now())
      newAppnt1.Description = "We sent you a proposal two days ago, did you take a look at it...."
      newAppnt1.Save
end sub

See Also