You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Unable to Save New Contact in CPM through Custom Script

Accepted answer
21
Views
19
Comments
edited Jun 24, 2016 8:23AM in Integrations and APIs 19 comments

Content

Hi All,

I am trying to Create new contact from CPM by simple Custom Script, i am just hard coding all field values and saving the record.Not getting any error , but could not able to see my new contact in database.I mean when i search for my contact record not found.

Can any one help me please..

 

Thanks,

Natraj

 

Version

i am using Feb 2016 version

Code Snippet

             $contact = new RNCPHP\Contact();
				//$Contact = RNCPHP\Contact::fetch(234);
				$contact->Name = new RNCPHP\PersonName();
				$contact->Name->First = "Nats";
				$contact->Name->Last = "buddhi";
				//$contact->Email = "[email protected]";
				//$contact->ID = "7074";
				$contact->Title_BFSI = "Mr";
				$contact->Login->Login = "kpabba";
				$contact->Disabled->Disabled = "No";
				$contact->save(RNCPHP\RNObject::SuppressAll);	
				RNCPHP\ConnectAPI::commit(); 
        

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!