• E_rock
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 2
    Replies

I have created a button on the Contact Object whcih will create a new Case and prepolulate many fields of the case.  I have logic in the code that looks to see if it's one reocrd type, create a Case with record type1.  Otherwise, create a case with record type2.  I am now trying to fill a picklist field on the Case with a specific value based upon a couple of variables which exist on the Account.  For some reason, it appears that I cannot accuratley put a condition whcih exists on the account?

 

&FieldID={!Case(Account.Field1__c ,
"Value1",(If(Account.Field2__c=True,"1","2")),
"Value2",(If(Account.Field2__c=True,"1","3"))"") }

 

I know the sytax is partially correct, becasue if I substuitute Account.Field1__c with Contact.Field1__c I see better resutls, but I still need to act upon a value that is in Account.Field2__c.  Can this be accomplished in basic button coding or is the only way to reference an account field with Apex or Java?

 

Any help would be appreciated.

 

  • September 04, 2013
  • Like
  • 0

I have created a report, that I am calling with a custom link.  Currently, I am passing  /#############?pv0={!Lead.Field} where ### is the report number.  I wanted to only pass the first four characters of thelead field and tried to use the left function to do so.  The result I get is not expected.  Instead of giving me only the first four characters, it passses the following Left(12321223,4).  In another words, it is retrieving the value of the field 12321223, but not utilizing the Left function functionality.  Is there a way to do what I am trying to do?  Pass only the first 'X" number of characters from a field?

  • April 02, 2012
  • Like
  • 0

Is there a function that I can use in a formula to determine the Time from a Date time field?   we have a need to create workflow based on if something occurrs before or after 4pm est.  Is this even possible?  Any help would be most appreciated, thanks.

  • January 12, 2012
  • Like
  • 0

A prior administrator created a custom button on the Contact object to create a new Case from the Contact Page layout.  The objective was to auto populate Contact and Account information when creating a new Case.  The code began this way 'https://na4.salesforce.com/500/e?retURL=%2F&cas4_lkid={!Account.Id}&cas3_lkid={!Contact.Id}&.........'  It works great, and recently we discovered an unwanted side effect.  If you click the 'Cancel button before saving the case, the user gets logged out of the SFDC instance.  A SFDC customer service representative told me it was becsause the code was hard coding a URL string into it, in essence 'hacking into our instance' causing the log out on the 'Cancel'.

 

Can anybody tell me a way around this or another approach in creating a new Case and autopopulating the fields with Accouont and Contact information?  Any assistnace is most appreciated.

  • January 09, 2012
  • Like
  • 0

A prior administrator created a custom button on the Contact object to create a new Case from the Contact Page layout.  The objective was to auto populate Contact and Account information when creating a new Case.  The code began this way 'https://na4.salesforce.com/500/e?retURL=%2F&cas4_lkid={!Account.Id}&cas3_lkid={!Contact.Id}&.........'  It works great, and recently we discovered an unwanted side effect.  If you click the 'Cancel button before saving the case, the user gets logged out of the SFDC instance.  A SFDC customer service representative told me it was becsause the code was hard coding a URL string into it, in essence 'hacking into our instance' causing the log out on the 'Cancel'.

 

Can anybody tell me a way around this or another approach in creating a new Case and autopopulating the fields with Accouont and Contact information?  Any assistnace is most appreciated.

  • January 09, 2012
  • Like
  • 0