• Gaurii
  • NEWBIE
  • 35 Points
  • Member since 2012

  • Chatter
    Feed
  • 1
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 21
    Questions
  • 10
    Replies
public class Code123Controller {
    public static boolean setValue{get; set;}
    @AuraEnabled
    public static String getUserList1() {
        String usrid = UserInfo.getUserId();
        
        return usrid;
    }
    
    @AuraEnabled
    public static boolean getCodeDetails(string userid,string Code ) {
        Code__c CodeList;
       
        //String usrid = UserInfo.getUserId() ; 
        try{
            CodeList = [SELECT Id,Active__c,Code__c FROM Code__c 
                            where Code__c=:Code AND Active__c = True];
            
               Code__c updateOwner = new Code__c();
                if(CodeList.Code__c == Code){
                    
                    overCodeList.OwnerId = CreatedbyId;
                    update CodeList;
                    setValue = true;
                }  
            
        }Catch(Exception e){
            setValue = false;  
            system.debug(e);
        }
        return setValue;
    }          
This page has an error. You might just need to refresh it. Access Check Failed! AttributeSet.set(): 'MainSection' of component 'markup://c:CS_CP_PortfolioDashboard_HeaderContainer {6:0}' is not visible to 'markup://c:CS_CP_TabContainer {9:4;a}'. Failing descriptor: {markup://c:CS_CP_TabContainer}
My query is not working i have the below query which works fine but when i try use Id in clause it doesnt show me any records.
'select id,profile.name from User where profile.name = \test1\' OR profile.name =\Test2\''; This works fine.
But the below one doesnt work.Could you please suggest?
select id from User where id in ('00eg0000000M4XY', '00eg0000000M3TR')
 
 
Can any one suggest how can we have validation rules on phone number field validating formats for different countries across Europe ?or any?
  • March 12, 2014
  • Like
  • 0

This morning I am noticing something strange when selecting to creating a Lead from the home menu in both Production and SB2.  I am basically logged out and am expected to enter my credentials again as per below: 

When I attempt to create an Account this is not an issue.  Could you please advise?  Thanks, 

  • November 12, 2013
  • Like
  • 0

I created a new campaign member status in each called "TM Contacted".  However, we have noticed that this campaign member disappears from the campaign after a while and so it is not possible to update members with this status.

Can any one let me know why this is happening ..please 

  • October 30, 2013
  • Like
  • 0

 Trying to add a filter criteria to a contact and lead list view but cannot find the field required.  We wish to use "Comments" field in both list views.thing is that I cannot see any "Comments" field in field admin either   

Could you please advise?

  • October 07, 2013
  • Like
  • 0

 Could there be a validation rule that if a Due Date or comment is entered then Subject field is required?Help

  • September 23, 2013
  • Like
  • 0

How to write trigger logic in class and call that class in trigger?Can anybody explain me with example?

  • March 11, 2013
  • Like
  • 0

How  can we  read the log files or log from salesforce and store that in a file as blob ?Guys plz help me out ...?

  • March 06, 2013
  • Like
  • 0

What is the piece about the Custom Support Setting in salesforce?

  • March 05, 2013
  • Like
  • 0

What is the piece about the Custom Support Setting in salesforce can anybody explain?

  • March 05, 2013
  • Like
  • 0

How to make owner as a defaulting to  queue upon creation of a  record?????

  • March 01, 2013
  • Like
  • 0

The field should be populate field named as action taken should populate on closure not on creation ie when my status is Resolved or Unable to resolve-EscalatetoPST.
My validation rule:

 

AND
((ISCHANGED(Status__c)),
And(OR(ISPICKVAL( Status__c,'Resolved'),
ISPICKVAL(Status__c,'Unable to resolve-EscalatetoPST')),
ISPICKVAL( Action_Taken__c,'')) )
its not working for Unable to resolve-EscalatetoPST only working for resolve. 

why? plz help

  • February 27, 2013
  • Like
  • 0
public class Code123Controller {
    public static boolean setValue{get; set;}
    @AuraEnabled
    public static String getUserList1() {
        String usrid = UserInfo.getUserId();
        
        return usrid;
    }
    
    @AuraEnabled
    public static boolean getCodeDetails(string userid,string Code ) {
        Code__c CodeList;
       
        //String usrid = UserInfo.getUserId() ; 
        try{
            CodeList = [SELECT Id,Active__c,Code__c FROM Code__c 
                            where Code__c=:Code AND Active__c = True];
            
               Code__c updateOwner = new Code__c();
                if(CodeList.Code__c == Code){
                    
                    overCodeList.OwnerId = CreatedbyId;
                    update CodeList;
                    setValue = true;
                }  
            
        }Catch(Exception e){
            setValue = false;  
            system.debug(e);
        }
        return setValue;
    }          
controller


public class accToPick 
{

   

    
List<Account> acc;
public String val{get;set;}
 public List<cContact> ist{get;set;}
  public String index {get;set;}
  
  public String fname{get;set;}
  public String lname{get;set;}
  

    public accToPick()
    {
    acc= [SELECT id,name FROM Account];
    
    
    
    }
    
        
 
    
    public List<SelectOption> getAccounnames() 
    {
        List<SelectOption> accOptions= new List<SelectOption>();
        for(Account acc2:acc)
            {
            
            accOptions.add(new selectOption(acc2.id,acc2.name));
            }
        return accOptions;
    }
    

    public List<cContact> conload()
    {    
          ist= new List<cContact>();
        for(Contact a:[SELECT id,name,email from Contact where Account.Id=:val])
        {
            ist.add(new cContact(a));
        }
        
         return null;
    }
    
    public void addContact()
        {
        Contact lc=new Contact(FirstName=fname,LastName=lname,AccountId=val);
        
            try
            {
                insert lc;
            }
            
            catch(Exception e)
            {
                ApexPages.addMessages(e);
            }
            conload();
            fname='';
            lname='';
        }
     
     public void deletecon()
     {
      Contact c1=[select id from Contact where id=:index];
      delete c1;
      conload();
     }
     
     public PageReference sendmail()
     {
         List<Contact> selectedContacts = new List<Contact>();
        
            
              
           
            
         
         //System.debug(selected + 'abc');
        for(cContact cCon :ist) 
        {
        
            if(cCon.selected==true) 
            {
                selectedContacts.add(cCon.con);
                
            }
            
        }
        System.debug('These are the selected Contacts…');
        for(Contact con : selectedContacts) 
        {
            string conEmail = con.Email;
            Messaging.SingleEmailMessage mail = new Messaging.SingleEmailMessage();
            String[] toAddresses = new String[] {conEmail};
            mail.setToAddresses(toAddresses);
            mail.setReplyTo('huria.99.anuj@gmail.com');
            mail.setSenderDisplayName('Salesforce Support');
            mail.setSubject('New Case Created : ' + case.Id);
            mail.setBccSender(false);
            mail.setUseSignature(false);
            mail.setPlainTextBody('Thank for Contacting');
            mail.setHtmlBody('Thank for Contacting');
            Messaging.sendEmail(new Messaging.SingleEmailMessage[] { mail });
        }
        return null;
     }
     
      public class cContact 
      {
        public Contact con {get; set;}
        public Boolean selected {get; set;}
        public cContact(Contact c)
        {
            con = c;
            selected = false;
        }
    }
    
    
}

 Trying to add a filter criteria to a contact and lead list view but cannot find the field required.  We wish to use "Comments" field in both list views.thing is that I cannot see any "Comments" field in field admin either   

Could you please advise?

  • October 07, 2013
  • Like
  • 0

 Could there be a validation rule that if a Due Date or comment is entered then Subject field is required?Help

  • September 23, 2013
  • Like
  • 0

The field should be populate field named as action taken should populate on closure not on creation ie when my status is Resolved or Unable to resolve-EscalatetoPST.
My validation rule:

 

AND
((ISCHANGED(Status__c)),
And(OR(ISPICKVAL( Status__c,'Resolved'),
ISPICKVAL(Status__c,'Unable to resolve-EscalatetoPST')),
ISPICKVAL( Action_Taken__c,'')) )
its not working for Unable to resolve-EscalatetoPST only working for resolve. 

why? plz help

  • February 27, 2013
  • Like
  • 0