Salesforce

An effort to bring a revolution in Salesforce.

Thursday, 30 June 2016

How to Installation box.com and Initial Setup Salesforce?



Installation Prerequisites Two Box accounts are required to install the Box for Salesforce integration:
  • Box Service Account:
    • to be used exclusively for integration purposes and does not belong to an individual end user, 
    • owns the Salesforce content on Box and makes API calls from Salesforce to Box for the entire enterprise
    • If you don’t already have a Box Service Account, create one (i.e., add boxforsalesforce@example.com as a managed user).
  • Box User Account: to link a user’s Salesforce account to their Box account.
Note: The Service Account and User Account must be two different accounts (although both can be managed users in your enterprise). The integration will not allow you to login with the same account in both places.

Two types of Salesforce accounts will access the Box for Salesforce integration:
  • Salesforce Admin Account:
    • to install packages in Salesforce in order to link the installed package to the Box Service Account
    • can also be a regular user of Box for Salesforce integrations.
  • Salesforce User Account: to link a Box User Account and access Box content.


Installing Box for Salesforce

  1. Log into Salesforce as a Salesforce Admin.
  2. Navigate to the package installation link.
  3. At separate points during the installation, you will be asked to:
    • Accept and Approve Third-Party Access for remote settings.
    • Grant access to all users.
    • Click Next or Continue in other screens to complete the installation.
  4. When you complete the installation, the screen will return to the Salesforce Box Connector App (Managed) page.

    box for salesforce setup.jpg
  5. Click the + tab to view the All Tabs page.
  6. Click Box Settings to view the Connect Salesforce to Box page.
  7. Click the Box API Admin Login button to view the Box API login page.
  8. Enter the Box Service Account credentials (see the Installation Prerequisites section above).

    box admin settings setup.jpg
  9. Specify the name for your Root Folder, e.g. Salesforce-<Org Identifier>.
  10. Specify folder settings for Lead conversions (optional)
  11. Specify your company's subdomain, e.g. if you log into Box at cloud.app.box.com, your subdomain is "cloud".
  12. At this point, you can enable (suggested) or disable Seamless Login and Auto-Collab on the same page, and click Save Settings. See the Enabling Auto-Collab for a User section below for more information.
  13. Add the Box functionality to Salesforce objects (e.g. Opportunities, Accounts, etc.) by following the steps under Embedding Box in a Salesforce Page.




Salesforce box integration.

, ,

Saturday, 18 June 2016

Salesforce auto-create folders for all Account? Box.com




 This is batch class use to auto-create folder for account .






global class autofolderCreator  implements Database.Batchable<sObject>,Database.Stateful,Database.AllowsCallouts{
  global

 Map<String,String> boxFmap = new Map<String,String>();
   global autofolderCreator(){
   }

   global Database.QueryLocator start(Database.BatchableContext BC){
        // this loop use to map existing folder with account so prevent for duplication.
       for(box__Folder_Meta__c mp :[select id,name,box__Folder_Id__c ,box__Folder_Name__c,box__Folder_Share_Link__c from box__Folder_Meta__c limit 9999]){
           boxFmap.put(mp.box__Folder_Name__c,mp.id); 
       }
      String query = 'Select id,name from account';
      return Database.getQueryLocator(query);
   }
  
   global void execute(Database.BatchableContext BC, List<Account> scope){
       box.Toolkit boxToolkit ;
       for(Account a : scope){
            if(!boxFmap.containsKey(a.name)){
                boxToolkit = new box.Toolkit();
                String accountFolderId = boxToolkit.createFolderForRecordId(a.id, null, true);
                boxToolkit.commitChanges();
            }
      } 
    }
   global void finish(Database.BatchableContext BC){
   }
}

 Box.com,Auto create folder for account.

, , ,

Get Gmail, Docs, Drive, and Calendar for business