function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
rentalforcerentalforce 

newbie can't create new event

hi - i am trying to create a new event as follows. the problem i am having is that it is successful according to save result array however no event is created. since there is no error reported, i have no clue what is wrong. any pointer is appreciated. thanks.

 

 

        Calendar now = Calendar.getInstance();

        Event e = new Event();

        e.setActivityDateTime(now);

        e.setSubject("Call");

        e.setIsAllDayEvent(false);

        e.setDurationInMinutes(new Integer(5));

     e.setWhoId(c.getId()); // here i have verified that i have a valid contact "c"

    SaveResult[] sr = binding.create(new Event[]{ e }); // here sr.success = true and errors = null