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
Karthik RajanKarthik Rajan 

Creating New custom object and showing it in new window using S-Control

Hi,
 
I wanted to create a custom object and show the entry screen for the same in S-Control .
Once the entry is done in S-control and Saved/pressed ok,I wanted to pass the value to the main window of the custom object which had defined the s-control.
 
Is there any example so to implement.
 
E.g:Main Object Like campaign Schedules has S-Control which defined Target Group,once defined from S-control i want the Target group entered to be passed to the main Campaign schedule object.
 
Regards,
Karthik Rajan
GlennAtAppirioGlennAtAppirio
Here's a sample, creating a Case object for a Contact, and then depositing the user on the "Edit" screen for the new case (and omitting error checking, record types, etc. for clarity):

Code:
var newCase = new sforce.SObject("Case"); 
newCase.ContactId = "{!Contact.Id}";
var saveResult = sforce.connection.create([newCase]); 
var newCaseId = saveResult[0].id;
parent.frames.location.replace("/" + newCaseId + "/e");