• Sachin Singh 1
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 4
    Replies
I am working on Activities. 
and due to data size all the size when we load the tab. It gets timed-out. So we have have created a view populating records created today.

but not able to set thie view as default.
I am new to Salesforce and not very much familier with the PageReferences etc.

Need help......This very urgent. 
Hi All,

I am using a email template, I wanted to put a hyperlink in this template named "Click on this".

When user click on this "Click on this" hyper link. User should it should redirect to the record/detail page.

This is very urgent. Please help.
 
Hi, I am new to SDFC and have created a email Service,the email created is workign as expected. 
But i am not able to write the test class for this.
My code for email servie is 
*******************************************************************
global class MyemailService implements Messaging.InboundEmailHandler {
      global Messaging.InboundEmailResult handleInboundEmail(Messaging.InboundEmail email, Messaging.InboundEnvelope envelope) {
          Messaging.InboundEmailResult result = new Messaging.InboundEmailresult();
              
          Task[] newTask = new Task[0];
          string IdfromSubject = email.subject.right(9);  
          system.debug('*****Records Unique Identifier is*****'+ IdfromSubject );
          
          if (IdfromSubject.left(2)=='UG'){
              Unclaimed_Gifts__c  Ugifts = new   Unclaimed_Gifts__c ();
              Ugifts= [select id from Unclaimed_Gifts__c where Unique_Identifier__c= : IdfromSubject];
             
              System.debug('Unclaimed Gift Id*******' + Ugifts.Id);
              newTask.add(new Task(Description = email.plainTextBody,
              Priority = 'Normal',           
              Subject = email.subject,
              IsReminderSet = true,           
              WhatId = Ugifts.Id));
          }
          else if(IdfromSubject.left(2)=='EG'){
              Expected_Gift__c Egifts = new Expected_Gift__c();
              Egifts= [select id from Expected_Gift__c where Unique_Identifier__c= : IdfromSubject];
              
              System.debug('Expected Gift Id*******' + Egifts.Id);
              newTask.add(new Task(Description = email.plainTextBody,
              Priority = 'Normal',           
              Subject = email.subject,
              IsReminderSet = true,           
              WhatId = Egifts.Id));              
          }                              
          try{
          insert newTask;
          }
          catch (System.QueryException e) {
              System.debug('***Could not be inserted....***');
          }
          return result;
      }
  }
*******************************************************************

 
I am noew to Salesforce and wanted to write the test class for the below code.......
Need help...

public class UnclaimedGiftsattachment
{
public Unclaimed_Gifts__c objcase{get;set;}
public Attachment myAttachment{get;set;}
public string fileName{get;set;} 
public Blob fileBody{get;set;}

    public UnclaimedGiftsattachment(Apexpages.standardcontroller controller)
    {
        objcase = new Unclaimed_Gifts__c();
        myAttachment =new Attachment();
    }
    public pagereference save()
    {
        insert objcase;
        System.debug('@@@@@fileBody'+fileBody);     
        myAttachment  = new Attachment();
              if (fileBody !=null){
                  Integer i=0;
                  myAttachment.clear();
                  myAttachment.Body = fileBody; 
                  myAttachment.Name = 'Logo_'+objcase.id+'.jpeg' ; 
                  myAttachment.ParentId = objcase.id;             
                  insert myAttachment;
              } 
        pagereference pr = new pagereference('/'+objcase.id);                           
        return pr;
    }
}
I am working on Activities. 
and due to data size all the size when we load the tab. It gets timed-out. So we have have created a view populating records created today.

but not able to set thie view as default.
I am new to Salesforce and not very much familier with the PageReferences etc.

Need help......This very urgent. 
Hi, I am new to SDFC and have created a email Service,the email created is workign as expected. 
But i am not able to write the test class for this.
My code for email servie is 
*******************************************************************
global class MyemailService implements Messaging.InboundEmailHandler {
      global Messaging.InboundEmailResult handleInboundEmail(Messaging.InboundEmail email, Messaging.InboundEnvelope envelope) {
          Messaging.InboundEmailResult result = new Messaging.InboundEmailresult();
              
          Task[] newTask = new Task[0];
          string IdfromSubject = email.subject.right(9);  
          system.debug('*****Records Unique Identifier is*****'+ IdfromSubject );
          
          if (IdfromSubject.left(2)=='UG'){
              Unclaimed_Gifts__c  Ugifts = new   Unclaimed_Gifts__c ();
              Ugifts= [select id from Unclaimed_Gifts__c where Unique_Identifier__c= : IdfromSubject];
             
              System.debug('Unclaimed Gift Id*******' + Ugifts.Id);
              newTask.add(new Task(Description = email.plainTextBody,
              Priority = 'Normal',           
              Subject = email.subject,
              IsReminderSet = true,           
              WhatId = Ugifts.Id));
          }
          else if(IdfromSubject.left(2)=='EG'){
              Expected_Gift__c Egifts = new Expected_Gift__c();
              Egifts= [select id from Expected_Gift__c where Unique_Identifier__c= : IdfromSubject];
              
              System.debug('Expected Gift Id*******' + Egifts.Id);
              newTask.add(new Task(Description = email.plainTextBody,
              Priority = 'Normal',           
              Subject = email.subject,
              IsReminderSet = true,           
              WhatId = Egifts.Id));              
          }                              
          try{
          insert newTask;
          }
          catch (System.QueryException e) {
              System.debug('***Could not be inserted....***');
          }
          return result;
      }
  }
*******************************************************************

 
I am noew to Salesforce and wanted to write the test class for the below code.......
Need help...

public class UnclaimedGiftsattachment
{
public Unclaimed_Gifts__c objcase{get;set;}
public Attachment myAttachment{get;set;}
public string fileName{get;set;} 
public Blob fileBody{get;set;}

    public UnclaimedGiftsattachment(Apexpages.standardcontroller controller)
    {
        objcase = new Unclaimed_Gifts__c();
        myAttachment =new Attachment();
    }
    public pagereference save()
    {
        insert objcase;
        System.debug('@@@@@fileBody'+fileBody);     
        myAttachment  = new Attachment();
              if (fileBody !=null){
                  Integer i=0;
                  myAttachment.clear();
                  myAttachment.Body = fileBody; 
                  myAttachment.Name = 'Logo_'+objcase.id+'.jpeg' ; 
                  myAttachment.ParentId = objcase.id;             
                  insert myAttachment;
              } 
        pagereference pr = new pagereference('/'+objcase.id);                           
        return pr;
    }
}