How can we define or declare a customer object in an apex class. so that we can use it for custom object fields for search criteria with the standard object fields.
oppr = [ SELECT Account, Name, Amount, CloseDate, StageName FROM Opportunity WHERE CloseDate = CustomReport__c.CloseDate__c];
return oppr; } }
In the above mentioned code i am getting unable to locate CustomReport. Here the search criteria is based on the closedate of the custom object CustomReport and the standard object Opporunity field closedate. So if any one knows how to declare a custom object in apex class can post their views.
sObject[] arrSObject = new sObject[1];
sObject sObj = new Sforce.sObject();
sObj.type = [Objectname];
// arrElement is the array of the fieldname and value XmlElement
sObj.Any = arrElements;
arrSObject[0] = sObj;
Sforce.SaveResult[] arrResult = m_service.create(arrSObject);
Hi,
How can we define or declare a customer object in an apex class. so that we can use it for custom object fields for search criteria with the standard object fields.
public class displayOpportunityDetails
{
// private CustomReport
private List<Opportunity> oppr;
private List<Opportunity> getOpportunityDetails()
{
oppr = [ SELECT Account, Name, Amount, CloseDate, StageName FROM Opportunity
WHERE CloseDate = CustomReport__c.CloseDate__c];
return oppr;
}
}
In the above mentioned code i am getting unable to locate CustomReport. Here the search criteria is based on the closedate of the custom object CustomReport and the standard object Opporunity field closedate. So if any one knows how to declare a custom object in apex class can post their views.
regards
Arun