• crmexpert
  • NEWBIE
  • 80 Points
  • Member since 2009

  • Chatter
    Feed
  • 3
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 6
    Questions
  • 17
    Replies

trigger Contact1i on Contact (before insert) {

for( Contact c : Trigger.new )

{

if( c.birthdate = null)

{

c.birthdate = 1968-09-09;

}

update c;

}

}

Hi,

 

Is it possible to have a trigger only fire on a record that is approved at the end of an approval process?

 

I have an after update trigger that does some cascading updates on associated child records. Now we want to introduce an approval process and only have the child updates happen on final approval of the change.

 

As I have not worked with approval processes before any help will be much appreciated.

  • April 17, 2009
  • Like
  • 0

Is there a way to check a variable's value during trigger execution?  I use alerts and echo statements in javascript and PHP code to accomplish this, but haven't seen anything yet like this for apex.

 

I've written some trigger code that compiles OK, but it doesn't actually do what I want it to do, so i need to debug this somehow.

 

As a newbie, I've probably missed something really obvious here!

 

Thanks,

Kevin

 

  • April 01, 2009
  • Like
  • 0

can anybody help me with any real life implementation example of 'Territory Management'??

i have studied TM but could not really relate it to any valid thing in real life..just got an overview of TM..oplease provide a good example so that i can get a hang of it..

 

 

thanks :)

i created 3 record types on Lead object.

the problem is i cannot delete those record types..

 

the error that i get is "This record type cannot be deactivated because the following profiles use this record type as default.   1. Customer Portal Manager 2. Standard Platform User"

 

there is no option in those profiles to deactivate the default record type.

 

if anybody has faced such a problem..please provide solution here..

 

thanks in advance..

from salesforce's perspective, i want to understand the actual difference between CUSTOMER and DEVELOPER ..because both use licenses to use the editions of salesforce..whether developer or enterprise or whatever..

 

please provide points and references..

 

Thanks :)

i am working on a vf controller..i need to sort the fields..not the values upon a particlular field..that is..i need the output as:

 

age,  billing city, .....firstname, gender, lastname ....

 

that is alphabetically sort the FIELDS!!..

 

does anybody have any idea...????

{!REQUIRESCRIPT("/soap/ajax/8.0/connection.js")}
{!requireScript("/soap/ajax/13.0/apex.js")}
var connection = sforce.connection;

var opp = new sforce.SObject("Ord__c");
alert(opp);

if ((opp.Status__c == "Submitted")  ||   (opp.Status__c== "Completed") ||  (opp.Status__c== "Shipping In Progress"))
{
      alert("The record cannot be submitted.  Only records that have the status ‘New Order’ may be submitted");
}
else
{

opp.Status__c="Submitted";
connection.update([opp]);
alert("Done.");
      
}

hi people,

 

i have a case. in that case there is a related list 'Activity History'.....

in that related list the activities are saved as tasks...i need to parse the task for getting things written in the 'body' field(in that task)..and take these entries and use it in the controller of the close case.

does any of you have any idea how to do this..

 

thanks in advance...

 

 

Todd

Hello,

I would like to automate the creation of an Account when a Contact is created and the Account Name is left blank.  Do I need Visual Force for this or is an Apex trigger sufficient? Could someone put me in the right direction?

Thanks

Pierre 

if i want to get data form recordcount=20 to 30, how to write the SOQL.

 

for example,it maybe [select rownum() as rownum,id from account where rownum  between 20 to 30]. 

 

help! 

HI,

Any help is much appreciated.  I am trying to find ways to force users to add at least one Contact when an Account is created.  I have spent hours looking at other posts requesting similar code, but don't know enough to put it all together for this particular request.  Is there a way (Trigger or S-control or what) that will take users to the Contact Edit page after creating a New Account? In addition it would be nice to do this at the Opportunity level as well with making sure Contact roles are associated with an Opportunity.

 

Thanks!

Liz

trigger Contact1i on Contact (before insert) {

for( Contact c : Trigger.new )

{

if( c.birthdate = null)

{

c.birthdate = 1968-09-09;

}

update c;

}

}

i created 3 record types on Lead object.

the problem is i cannot delete those record types..

 

the error that i get is "This record type cannot be deactivated because the following profiles use this record type as default.   1. Customer Portal Manager 2. Standard Platform User"

 

there is no option in those profiles to deactivate the default record type.

 

if anybody has faced such a problem..please provide solution here..

 

thanks in advance..

Can anybody tell me what the required parameters for a Single Email Message are (Messaging.SingleEmailMessage)? I am trying to debug a trigger that sends one that we have created that uses a Visual Force email template. My test method continuously fails because according to the debug log a Parameter value is null.
  • April 23, 2009
  • Like
  • 0

from salesforce's perspective, i want to understand the actual difference between CUSTOMER and DEVELOPER ..because both use licenses to use the editions of salesforce..whether developer or enterprise or whatever..

 

please provide points and references..

 

Thanks :)

Hi,

 

Is it possible to have a trigger only fire on a record that is approved at the end of an approval process?

 

I have an after update trigger that does some cascading updates on associated child records. Now we want to introduce an approval process and only have the child updates happen on final approval of the change.

 

As I have not worked with approval processes before any help will be much appreciated.

  • April 17, 2009
  • Like
  • 0

I'm going to create a trigger on case object, this trigger should only invoke when the case're record type is "XXX", "XXX" is one of the record type of case, can someone help me figure out the code to identify the report type is "XXX". the following script doesn't work.

if(Trigger.new[i].RecordType == 'Partner Case'){

i am working on a vf controller..i need to sort the fields..not the values upon a particlular field..that is..i need the output as:

 

age,  billing city, .....firstname, gender, lastname ....

 

that is alphabetically sort the FIELDS!!..

 

does anybody have any idea...????

Is there a way to check a variable's value during trigger execution?  I use alerts and echo statements in javascript and PHP code to accomplish this, but haven't seen anything yet like this for apex.

 

I've written some trigger code that compiles OK, but it doesn't actually do what I want it to do, so i need to debug this somehow.

 

As a newbie, I've probably missed something really obvious here!

 

Thanks,

Kevin

 

  • April 01, 2009
  • Like
  • 0

Hi,

 

Is there are any option for system administrator to set the default record type for other user in a batch ?

 

The Record Type Selection setting , that is done through

 

Set Up --My Personal Information -- Record Type Selection.

 

Can that be done by system administrator for all other user ?

 

Thanks and Regards,

Dinesh Nasipuri

Dinesh.Nasipuri@gmail.com