• Arkadiy Golovko
  • NEWBIE
  • 0 Points
  • Member since 2016

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

What I'm trying to do is be able to have leads automatically convert to contacts if there is an account in the system for that company. I think that's the best way to describe it. For example, if there is an account already in Salesforce for Comerica Bank and we recieve a lead from a webform submission that works at Comerica as well, I would like that lead to automatically convert to a contact in that scenario. Another example is if there is an account for Chevrolet in Salesforce but there are still leads in the system that work at Chevrolet we would like those leads to convert over as contacts as well since they match the company. Any help would be appreciated!

Thanks!
  • November 16, 2016
  • Like
  • 0
getting "invalid cross reference id" error on running the below code in test class .

@isTest 
public class TestForceForecasting {
    static testMethod void insertNewUser() {
       
       User userToCreate = new User();
       
       userToCreate.FirstName = 'Davidsh';
       userToCreate.LastName  = 'Liush';
       userToCreate.Email     = 'dashwinsfdc99@gmail.com';
       userToCreate.Username  = 'sfdc-shdreamer@gmail.com';
       userToCreate.Alias     = 'fatty';
      userToCreate.TimeZoneSidKey  = 'GMT';
       userToCreate.LocaleSidKey  = 'en_US';
       userToCreate.EmailEncodingKey  = 'UTF-8';
       userToCreate.LanguageLocaleKey = 'en_US';
        userToCreate.ProfileId='00e28000005Mf8h';
       insert userToCreate;
       
       }
       }
Hello Experts,

I'm new to salesforce development and recently started writing apex classes. I got a requirement that uploads/download files using BOX external storage, for this I wrote visualforce page for upload/download and controllet to Http callouts to Box. In order to push this to prod we need to have a Unit test on this apex class. Here how can we write a test on this controller which contains https callouts? Please suggest.

Thanks,
Sumant K
Hi,
I have a word document stored in the Documents tab in Salesforce.
I need to add its download link in the email body section, that I am sending through VF page and apex controller class.
In my controller class, I tried querying the document object and used its ID for hyperlink, but that takes me to the folder where I have stored the file. I want the download to automatically start if the user clicks on this download link in his email. Can anyone please help?
Thanks !