• szesze20
  • NEWBIE
  • 10 Points
  • Member since 2011

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 1
    Likes Given
  • 15
    Questions
  • 3
    Replies
If anyone is stuck on #3 Create Seed Agency --> Filter Agency Records step when running the data flow (which I did with many attempts), I finally got it to run by unchecking the 'Use SAQL filter' box in the 'Filter Agency Records' node (I guess I should have read the SAQL online docs closer). Thought I'd share even though this might have been obvious for some folks:
User-added image
Our org is cleaning up some old objects. What is the best practice? I have 2 questions:
  1. Some dependencies I can think of are: Identifying dependencies such as Workflows or formula fields using these objects? Any other dependencies we should consider?
  2. Rather than manual, is there a way to search/export from eclipse, workbench for all workflows, formula fields that use these objects? 
  3. Whats the best way to mass-query date of last record created/modified for each of these old objects using API names? thanks.
We have over 200 layouts, and want to export a list of all Fields (with their Read Only/Required property, API name) for all Page Layouts. What is the best way to achieve this? Is it eclipse or is there better tool? thanks.
I implemented a VF page using describeTabs() but I underestand this is only for the logged-in user:
<apex:page >
   
<html>
 <head>
<apex:includeScript value="/soap/ajax/17.0/connection.js"/>
<script type="text/javascript">
function displayTabs(tabs) {
 
for( var i=0; i<tabs.length; i++) {
var tab = tabs[i];document.write(
" " + tab.label + " " + tab.sobjectName );
document.write("<br />");
}
document.write("<br />");
}
 
 
 sforce.connection.sessionId = '{!$Api.Session_ID}';
try {var
result = sforce.connection.describeTabs();
} catch(error) {
document.write(error);
}for
(var i=0; i < result.length; i++) {var tabSet = result[i];
document.write (tabSet.label);
document.write("<br />");
var tabs = tabSet.get("tabs");
displayTabs(tabs);
}
</script>
  </head>
<body >
 
</body>
</html>
</apex:page>

And I am able to get the result like this in the screenshot.
User-added image

But, here's what I want to do: A custom VF page for admin to pull the same result but for *all* users, not just logged in user. Is there a call similar  to describeTabs() but for all users? thanks.
For a non-programmer with almost no working knowledge of API, how do I make use and implement using describeTabs(). It says in SOAP API guide, "Returns info about standard and custom app available to logged in user as listed on top app menu" and this is what our group needs desperately but we don't have a programmer, nor do we have the budget to hire contractor to do it Pls. advise how a SFDC Admin can use this API to develop a quick and simple tool to pull the info needed. thanks!
I'm trying to write a SOQL query with appropriate joins, to see what Profile has access to what Custom Apps and Console. I see that in Workbench and Developer Console I can construct and execute a SOQL, but I'm very new to SOQL. I don't see a field/column in Profile object that shows the App ID or any key to the list of Apps. but this post (https://success.salesforce.com/answers?id=90630000000D9noAAC) suggests that this can be done. Can anyone point me to how to construct such SOQL? thanks.
We are doing an inventory of installed packages and apps, then what Profiles have visibility/access to each App/Package. 
I am able to export complete list of Apps from our org via dataloader, but is there a way take an inventory of which Profile has access to waht App, without having to click through each one in Setup? thanks
I turned on debug log for a User, logged in as that User, and test editing a Contact record. But then get the error when saving:
"You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary."

However, I don't see any Debug Log to troubleshoot. Any idea why?
 
We are doing an inventory of installed apps, what Profiles have visibility/access to each App. What's the best to take such an inventory without having to click through each one in Setup? thanks
I'm following the examples in https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/events_one_demo_load.htm but when I tried to save the contactList.cmp code in step 2, it threw an error:

Failed to save undefined: An unexpected error occurred. Please include this ErrorId if you contact support: 2024919742-80507 (-1984777881)

I did what was suggested in step 1: to replace namespace with my own namespace, but still it wouldn't save the file: contactList.cmp. Pls advise.
I just started playing with Lightning and have created controller and cmp. Intended behavior:
  1. User enters text in 'Find Travelingspoon' field, click Submit, it displays text 'Hi, [text]' - this part works fine.
  2. When user clicks 'Clear  button on Salesforce1, it clears whatever text is in the 'Find Traveling Spoon' text box, but it's not clearing out the text, the text stays in the box.
Please advise what's wrong. Thanks.

Here's my component code:
<aura:component implements="force:appHostable" access="global">
    
    <ui:inputText aura:id="name" label="Find TravelingSpoon:"/>
    
    <ui:button aura:id="button" buttonTitle="Submit Input" class="button" label="Submit" press="{!c.getInput}"/>
    <ui:outputText aura:id="outName" value="" class="text"/>

    <ui:button aura:id="button" buttonTitle="Clear the field" class="button" label="Clear" press="{!c.clearName}"/>    
    
</aura:component>

Here's my controller code:
({
    getInput : function(cmp, evt) {
        var myName = cmp.find("name").get("v.value");
        var myText = cmp.find("outName");
        var greet = "Hi, " + myName;
        myText.set("v.value", greet);
        cmp.set("v.value", []);
    }
})

({
    clearName : function(cmp, evt) {
    cmp.find("outName").set("v.value", "");
}

    }
    )
I implemented SFDC sample FindNearbyWarehousesPage VF page and it was working and able to load google map until I created namespace in my org. Now it won't load anything when I click on FindWarehouse tab, it just gives a blank page (same thing on both desktop and salesforce1). Is it something to the new namespace? 

When I click the tab, the URL gives: https://a2z.na10.visual.force.com/apex/FindNearbyWarehousesPage?sfdc.tabName=01rF00000003KVR where a2z is the newly created namespace

here's code for FindNearbyWarehousesPage:

<apex:page sidebar="false" showheader="false" standardController="Warehouse__c" extensions="FindNearbyExt">
    
    <!-- Include in Google's Maps API via JavaScript static resource -->
    <apex:includeScript value="{!$Resource.googleMapsAPI}" /> 
    
    <!-- Set this API key to fix JavaScript errors in production -->
    <!--http://salesforcesolutions.blogspot.com/2013/01/integration-of-salesforcecom-and-google.html-->
    <!--<script type="text/javascript" 
        src="https://maps.googleapis.com/maps/api/js?key=YOUR_API_KEY&sensor=false"> 
        </script>-->
        
    <!-- Setup the map to take up the whole window --> 
    <style>
        html, body { height: 100%; }
        .page-map, .ui-content, #map-canvas { width: 100%; height:100%; padding: 0; }
        #map-canvas { height: min-height: 100%; }
    </style>
    
    <script>
        function initialize() {
            var lat, lon;
              
             // If we can, get the position of the user via device geolocation
             if (navigator.geolocation) {
                 navigator.geolocation.getCurrentPosition(function(position){
                     lat = position.coords.latitude;
                     lon = position.coords.longitude;                    
                     
                     // Use Visualforce JavaScript Remoting to query for nearby warehouses      
                     Visualforce.remoting.Manager.invokeAction('{!$RemoteAction.FindNearbyExt.getNearby}', lat, lon,
                         function(result, event){
                             if (event.status) {
                                 console.log(result);
                                 createMap(lat, lon, result);           
                             } else if (event.type === 'exception') {
                                 //exception case code          
                             } else {
                                            
                             }
                          }, 
                          {escape: true}
                      );
                  });
              } else {
                  // Set default values for map if the device doesn't have geolocation capabilities
                    /** San Francisco **/
                    lat = 37.77493;
                    lon = -122.419416;
                    
                    var result = [];
                    createMap(lat, lon, result);
              }
          
         }
    
         function createMap(lat, lon, warehouses){
            // Get the map div, and center the map at the proper geolocation
            var currentPosition = new google.maps.LatLng(lat,lon);
            var mapDiv = document.getElementById('map-canvas');
            var map = new google.maps.Map(mapDiv, {
                center: currentPosition, 
                zoom: 13,
                mapTypeId: google.maps.MapTypeId.ROADMAP
            });
            
            // Set a marker for the current location
            var positionMarker = new google.maps.Marker({
                map: map,
                position: currentPosition,
                icon: 'http://maps.google.com/mapfiles/ms/micons/green.png'
            });
            
                        
            // Keep track of the map boundary that holds all markers
            var mapBoundary = new google.maps.LatLngBounds();
            mapBoundary.extend(currentPosition);
            
            // Set markers on the map from the @RemoteAction results
            var warehouse;
            for(var i=0; i<warehouses.length;i++){
                warehouse = warehouses[i];
                console.log(warehouses[i]);
                setupMarker();
            }
            
            // Resize map to neatly fit all of the markers
            map.fitBounds(mapBoundary);

           function setupMarker(){ 
                var warehouseNavUrl;
                
                // Determine if we are in Salesforce1 and set navigation link appropriately
                try{
                    if(sforce.one){
                        warehouseNavUrl = 
                            'javascript:sforce.one.navigateToSObject(\'' + warehouse.Id + '\')';
                    }
                } catch(err) {
                    console.log(err);
                    warehouseNavUrl = '\\' + warehouse.Id;
                }
                
                var warehouseDetails = 
                    '<a href="' + warehouseNavUrl + '">' + 
                    warehouse.Name + '</a><br/>' + 
                    warehouse.Street_Address__c + '<br/>' + 
                    warehouse.City__c + '<br/>' + 
                    warehouse.Phone__c;
               
               // Create the callout that will pop up on the marker     
               var infowindow = new google.maps.InfoWindow({ 
                   content: warehouseDetails
               });
               
               // Place the marker on the map   
               var marker = new google.maps.Marker({
                   map: map,
                   position: new google.maps.LatLng( 
                                   warehouse.Location__Latitude__s, 
                                   warehouse.Location__Longitude__s)
               });
               mapBoundary.extend(marker.getPosition());
               
               // Add the action to open up the panel when it's marker is clicked      
               google.maps.event.addListener(marker, 'click', function(){
                   infowindow.open(map, marker);
               });
           }
        }
        
        // Fire the initialize function when the window loads
        google.maps.event.addDomListener(window, 'load', initialize);
        
    </script>
    
    <!--  All content is rendered by the Google Maps code -->
    <!--  This minimal HTML justs provide a target for GMaps to write to -->
    <body style="font-family: Arial; border: 0 none;">
        <div id="map-canvas"></div>
    </body>
</apex:page>


 
Is there a way to download all workflows from eclipse?

Hi, when I save the below formula, it gave error:

 

Error: Invalid Data.

Review all error messages below to correct your data.

Formula(s) that reference this field are no longer valid: Compiled formula is too big to execute (5,735 characters). Maximum size is 5,000 characters

 

I'm looking for help to rewrite this formula to stay below the limit. Thanks in advance!

 

(
IF  (ISPICKVAL (Carrier__c, "Main"), 
	(
	IF ( LEN( Plan_Name__c ) = 0, 0 , 1 ) +
	IF ( ISPICKVAL (Carrier__c, ""), 0, 1 +
	IF ( ISPICKVAL(Product_Cat__c, ""), 0, 1 +
	IF ( ISPICKVAL(Product__c, ""), 0, 1) +
	IF ( ISPICKVAL(Account_Type__c, ""), 0, 1) +
	IF ( ISPICKVAL( This_Plan_Covers__c ,"") , 0 , 1 ) +
	IF ( ISPICKVAL( Type__c ,"") , 0 , 1 ) + 
	IF ( ISPICKVAL(Status__c, ""), 0, 1) +
	IF ( ISBLANK(Effective__c), 0, 1)) + 
	IF ( ISBLANK(Effective_Through__c), 0, 1)) +
	IF ( ISPICKVAL(Payment__c, ""), 0, 1) +
	IF ( ISPICKVAL(Rate_Step_T1__c, "") , 0 , 1 ) + 
	IF ( ISNULL(Rate__c), 0 , 1 )
	),
(
IF ( LEN( Plan_Name__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( This_Plan_Covers__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Type__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Network__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Rate_Type__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Rate_Position__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL(Rate_Step_T1__c, "") , 0 , 1 ) + 
IF ( ISNULL(Enrolled_T1__c), 0 , 1 ) + 
IF ( ISNULL(Rate__c), 0 , 1 ) + 
IF ( ISNULL(EE_Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(ER_Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(Ratio_T1__c), 0 , 1 ) + 
IF ( ISPICKVAL(Rate_Step_T2__c, "") , 0 , 1 ) + 
IF ( ISNULL(Enrolled_T2__c), 0 , 1 ) + 
IF ( ISNULL(Rate_T2__c), 0 , 1 ) + 
IF ( ISNULL(Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(Contribution_T2__c), 0 , 1 ) + 
IF ( ISNULL(Ratio_T2__c), 0 , 1 ) + 
IF ( ISPICKVAL( Primary_Care_Co_pay_Co_ins_PC__c ,"") , 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_PC__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Specialist_Care_Co_pay_Co_ins_SC__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_SC__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Generic_Drugs_Co_pay_Co_ins_RxG__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_RxG__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Outpatient_Surgery_Co_pay_Co_ins_OS__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_OS__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Emergency_Room_Co_pay_Co_ins_ER__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_ER__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Inpatient_Hospital_Co_pay_Co_ins_IH__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_IH__c ) = 0, 0 , 1 )
)
/(IF (ISPICKVAL (Carrier__c, "Main"), 13, 30))))

 

Hi, I'm brand new to Visualforce, and I'm not a programmer by training, so please bear with me. 

 

We implemented SFDC Customer Portal but put our own skin on it, and it's part of our corporate website that requires customer to log in before accessing the Portal area.

 

I recently built a VF page which is a form, but I'd like to implement so that when a customer submit the form from this VF page URL, they will be prompted to log into our corporate site, get authenticated, and then the VF form will insert a new record in a custom object in SFDC.

 

What is your recommendation? Thanks in advance!

I'm following the examples in https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/events_one_demo_load.htm but when I tried to save the contactList.cmp code in step 2, it threw an error:

Failed to save undefined: An unexpected error occurred. Please include this ErrorId if you contact support: 2024919742-80507 (-1984777881)

I did what was suggested in step 1: to replace namespace with my own namespace, but still it wouldn't save the file: contactList.cmp. Pls advise.
I'm following the examples in https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/events_one_demo_load.htm but when I tried to save the contactList.cmp code in step 2, it threw an error:

Failed to save undefined: An unexpected error occurred. Please include this ErrorId if you contact support: 2024919742-80507 (-1984777881)

I did what was suggested in step 1: to replace namespace with my own namespace, but still it wouldn't save the file: contactList.cmp. Pls advise.
I just started playing with Lightning and have created controller and cmp. Intended behavior:
  1. User enters text in 'Find Travelingspoon' field, click Submit, it displays text 'Hi, [text]' - this part works fine.
  2. When user clicks 'Clear  button on Salesforce1, it clears whatever text is in the 'Find Traveling Spoon' text box, but it's not clearing out the text, the text stays in the box.
Please advise what's wrong. Thanks.

Here's my component code:
<aura:component implements="force:appHostable" access="global">
    
    <ui:inputText aura:id="name" label="Find TravelingSpoon:"/>
    
    <ui:button aura:id="button" buttonTitle="Submit Input" class="button" label="Submit" press="{!c.getInput}"/>
    <ui:outputText aura:id="outName" value="" class="text"/>

    <ui:button aura:id="button" buttonTitle="Clear the field" class="button" label="Clear" press="{!c.clearName}"/>    
    
</aura:component>

Here's my controller code:
({
    getInput : function(cmp, evt) {
        var myName = cmp.find("name").get("v.value");
        var myText = cmp.find("outName");
        var greet = "Hi, " + myName;
        myText.set("v.value", greet);
        cmp.set("v.value", []);
    }
})

({
    clearName : function(cmp, evt) {
    cmp.find("outName").set("v.value", "");
}

    }
    )

Hi, when I save the below formula, it gave error:

 

Error: Invalid Data.

Review all error messages below to correct your data.

Formula(s) that reference this field are no longer valid: Compiled formula is too big to execute (5,735 characters). Maximum size is 5,000 characters

 

I'm looking for help to rewrite this formula to stay below the limit. Thanks in advance!

 

(
IF  (ISPICKVAL (Carrier__c, "Main"), 
	(
	IF ( LEN( Plan_Name__c ) = 0, 0 , 1 ) +
	IF ( ISPICKVAL (Carrier__c, ""), 0, 1 +
	IF ( ISPICKVAL(Product_Cat__c, ""), 0, 1 +
	IF ( ISPICKVAL(Product__c, ""), 0, 1) +
	IF ( ISPICKVAL(Account_Type__c, ""), 0, 1) +
	IF ( ISPICKVAL( This_Plan_Covers__c ,"") , 0 , 1 ) +
	IF ( ISPICKVAL( Type__c ,"") , 0 , 1 ) + 
	IF ( ISPICKVAL(Status__c, ""), 0, 1) +
	IF ( ISBLANK(Effective__c), 0, 1)) + 
	IF ( ISBLANK(Effective_Through__c), 0, 1)) +
	IF ( ISPICKVAL(Payment__c, ""), 0, 1) +
	IF ( ISPICKVAL(Rate_Step_T1__c, "") , 0 , 1 ) + 
	IF ( ISNULL(Rate__c), 0 , 1 )
	),
(
IF ( LEN( Plan_Name__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( This_Plan_Covers__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Type__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Network__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Rate_Type__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL( Rate_Position__c ,"") , 0 , 1 ) + 
IF ( ISPICKVAL(Rate_Step_T1__c, "") , 0 , 1 ) + 
IF ( ISNULL(Enrolled_T1__c), 0 , 1 ) + 
IF ( ISNULL(Rate__c), 0 , 1 ) + 
IF ( ISNULL(EE_Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(ER_Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(Ratio_T1__c), 0 , 1 ) + 
IF ( ISPICKVAL(Rate_Step_T2__c, "") , 0 , 1 ) + 
IF ( ISNULL(Enrolled_T2__c), 0 , 1 ) + 
IF ( ISNULL(Rate_T2__c), 0 , 1 ) + 
IF ( ISNULL(Contribution_T1__c), 0 , 1 ) + 
IF ( ISNULL(Contribution_T2__c), 0 , 1 ) + 
IF ( ISNULL(Ratio_T2__c), 0 , 1 ) + 
IF ( ISPICKVAL( Primary_Care_Co_pay_Co_ins_PC__c ,"") , 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_PC__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Specialist_Care_Co_pay_Co_ins_SC__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_SC__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Generic_Drugs_Co_pay_Co_ins_RxG__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_RxG__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Outpatient_Surgery_Co_pay_Co_ins_OS__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_OS__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Emergency_Room_Co_pay_Co_ins_ER__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_ER__c ) = 0, 0 , 1 ) + 
IF ( ISPICKVAL( Inpatient_Hospital_Co_pay_Co_ins_IH__c ,""), 0 , 1 ) + 
IF ( LEN( Co_pay_Co_ins_IH__c ) = 0, 0 , 1 )
)
/(IF (ISPICKVAL (Carrier__c, "Main"), 13, 30))))

 

I'm not a developer so I'm really trying to work through this challenge and can't figure this out.

I am getting the following error: The client side controller does not have a 'calculate' method when trying to figure out the Using Javascript with Components Lightning Trailhead module.

Here is the challenge:

Your company needs an interface that shows a calculation based on three inputs. The correct value must be the addition of the first two inputs and subtraction of the third. Create a form and client side controller to calculate the total.The component must be named 'CalculateTotal'.

-The component should have three aura:inputNumber components with ID's 'inputOne', 'inputTwo', and 'inputThree'.
-The total must be displayed using a aura:outputNumber component with the ID 'totalValue'
-The client-side controller must do the calculation in a method named 'calculate'.
-The client-side controller can use the standard JavaScript function parseInt to enforce the data type.
-The component must invoke the 'calculate' method on the client-side controller to perform the calculation.

Here is my component:
<aura:component >
<form>
    <fieldset>
    Enter three values:<br/>
    <ui:inputNumber aura:Id="inputOne" value="{!v.inputOne}"/><br/>
    <ui:inputNumber aura:Id="inputTwo" value="{!v.inputTwo}"/><br/>
    <ui:inputNumber aura:Id="inputThree" value="{!v.inputThree}"/><br/>
    <ui:button label="Submit" press="{!c.calculate}"/><br/>
    <ui:outputNumber aura:id="totalValue" value="{!v.totalValue}"/><br/>
    </fieldset>
</form>
</aura:component>

Here is my controller: 
({

    calculate: function(component, item, callback) {
        component.find("inputOne").get("v.inputOne");
        component.find("inputTwo").get("v.inputTwo");
        component.find("inputThree").get("v.inputThree");
        var action = component.get("c.calculateTotal");
        var this.totalValue = InputOne + InputTwo -InputThree;
        
        InputOne = parseInt({!v.InputOne});
        InputTwo = parseInt({!v.InputTwo});
        InputThree = parseInt({!v.InputThree});

        action.setCallback(this,function(a) {
            component.set("v.totalValue",a.getReturnValue());
        });
        $A.enqueueAction(action);
    },
})
}