-
ChatterFeed
-
0Best Answers
-
0Likes Received
-
0Likes Given
-
7Questions
-
4Replies
login to salesforce rather than username/password and sessionID/serverURL
- moeoo
- October 05, 2007
- Like
- 0
- Continue reading or reply
Update method - to override with empty string
Customer__c objCustomer = new Customer__c();
objCustomer.Account__c = "1234"; //String data type
SaveResult[] sr = binding.create(new sObject[] { objCustomer });
//Update customer
objCustomer.Account__c = "";
objCustomer.Id = _SalesforceID;
SaveResult[] sr = binding.update(new sObject[] { objCustomer });
I want the Account__c value to be empty string but it is not updated. If I put some value (e.g "1122"), it is updated.
Do I need to set any other value if I want to pass empty string?
Thanks in advance
Moe
- moeoo
- September 24, 2007
- Like
- 0
- Continue reading or reply
Time zone difference
- moeoo
- August 29, 2007
- Like
- 0
- Continue reading or reply
select available value from custom pick list field
- moeoo
- August 14, 2007
- Like
- 0
- Continue reading or reply
Populate Custom object's fields to template
records = queryResponse.getArray("records");
var contactID = records[0].Id;
var contactEmail = records[0].Email;
//alert(contactID);
var ids = new Array();
ids[0] = contactID;
massRequest.targetObjectIds = ids;
//alert(massRequest.targetObjectIds);
massRequest.subject = "test";
massRequest.replyTo = user;
massRequest.templateId = templatedId ;
try
{
var sendMailRes = sforce.connection.sendEmail([massRequest]);
alert('Email sent to user id: ' + contactEmail);
catch(err) {
alert(err)
}
- moeoo
- August 08, 2007
- Like
- 0
- Continue reading or reply
S-control - Parent child relationship
I have Account object which has many Products.
Products has three Record Types: Prod1, Prod2 and Prod3.
I'm trying to build a s-control and I want to get the data from one of the Record Types.
I know the Account ID but how can I get the details from record type?
Do I need to have a query statement for this? If so, can you provide me the example or syntax?
Thanks
- moeoo
- August 03, 2007
- Like
- 0
- Continue reading or reply
Create Contact object by passing existing Account object
private Account m_Account = null; //Salesforce account (build-in Account object)
Contact objContact = new Contact();
objContact.FirstName = m_FirstName;
objContact.LastName = m_LastName;
objContact.Phone = m_Phone;
objContact.Account = m_Account;
After I assign the contact.Account, I'm getting following error and contact object is not created.
More than 1 field provided in an external foreign key reference in entity: Account
I hope I'm doing the right thing here. If not, is there any way I can create a Contact object using existing Account Object.
Thanks in advance
- moeoo
- August 01, 2007
- Like
- 0
- Continue reading or reply
Update method - to override with empty string
Customer__c objCustomer = new Customer__c();
objCustomer.Account__c = "1234"; //String data type
SaveResult[] sr = binding.create(new sObject[] { objCustomer });
//Update customer
objCustomer.Account__c = "";
objCustomer.Id = _SalesforceID;
SaveResult[] sr = binding.update(new sObject[] { objCustomer });
I want the Account__c value to be empty string but it is not updated. If I put some value (e.g "1122"), it is updated.
Do I need to set any other value if I want to pass empty string?
Thanks in advance
Moe
- moeoo
- September 24, 2007
- Like
- 0
- Continue reading or reply
Time zone difference
- moeoo
- August 29, 2007
- Like
- 0
- Continue reading or reply
select available value from custom pick list field
- moeoo
- August 14, 2007
- Like
- 0
- Continue reading or reply
Create Contact object by passing existing Account object
private Account m_Account = null; //Salesforce account (build-in Account object)
Contact objContact = new Contact();
objContact.FirstName = m_FirstName;
objContact.LastName = m_LastName;
objContact.Phone = m_Phone;
objContact.Account = m_Account;
After I assign the contact.Account, I'm getting following error and contact object is not created.
More than 1 field provided in an external foreign key reference in entity: Account
I hope I'm doing the right thing here. If not, is there any way I can create a Contact object using existing Account Object.
Thanks in advance
- moeoo
- August 01, 2007
- Like
- 0
- Continue reading or reply