• BijayS
  • NEWBIE
  • 40 Points
  • Member since 2013
  • Senior Salesforce Developer
  • Adobe System

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 12
    Replies
I am not sure whats the issue or i misunderstood the problem statement :

User-added image

my code :

public class StringArrayTest {
    public static List<String> generateStringArray(Integer num) {
        List<String> generateString = new List<String>();
        
        for(Integer i = 0; i <= num ; i++) {
            string formattedString = 'Test ' + i;
            generateString.add(formattedString);
        }
        System.debug(LoggingLevel.INFO, 'Formatted String for Trail Head'+generateString);
        return generateString;
    }
}

Could anyone help me understand the issue even though its silly :)
  • November 14, 2015
  • Like
  • 0
User-added image

My Apex Class looks like this :

public class StringArrayTest {
    public static List<String> generateStringArray(Integer n) {
    
        List<String> generateString = new List<String>();
        
        for(Integer i = 0; i <= n ; i++) {
            string formattedString = 'Test ' + i;
            generateString.add(formattedString);
        }
        System.debug(LoggingLevel.INFO, 'Formatted String for Trail Head'+generateString);
        return generateString;
    }
}

Not Sure whats wrong here that i am getting the error.
  • October 23, 2015
  • Like
  • 0
Error during taking the challenge

Even though my developer org has the Lightning App "My Data" its saying app is not available.
  • October 19, 2015
  • Like
  • 0
Hello,
I am experiencing an issue while verifying step 7 of the Lightning Component Framework Specialist superbadge.

User-added image
The boat id is being set correctly when I filling in the form and the created record also has the Boat__c field filled in. I have been trying several ways to get past the verification, but I haven't been able to get past it. Does anyone see what I am doing wrong? Below you are able to see the onInit function.
 
onInit : function(cmp, evt) {
        cmp.find("service").getNewRecord(
            "BoatReview__c", 
            null,       
            false,     
            $A.getCallback(function() {                                 
                var error = cmp.get("v.recordError");
                if(error || (rec === null)) {
                    console.log("Error initializing record template: " + error);
                    return;
                }
                else {
                    var rec = cmp.get("v.boatReview");
                    rec.Boat__c = cmp.get('v.boat').Id;
                	cmp.set('v.boatReview', rec);
                }                
            })
        );
	}



 
I'm trying to complete the Handle Record Changes and Errors module but can't seem to get past the following challenge error:
Challenge Not yet complete... here's what's wrong: 
The 'accEdit' Lightning Component JS Controller does not appear to be setting 'v.recordSaveError' with an error message.

.I've tried many different combinations of sets and am not having much luck.

I've tried several different component.set methods such as this one:
component.set('v.recordSaveError','Error: ' + saveResult.state + ', message: ' + JSON.stringify(saveResult.error));

Any ideas what this module is looking for as a valid solution?

I do see recordSaveError display after being set due to an error.

Thanks.
 
Everytime I check challenge on Security Specialist Superbadge step 5 ("Set report, dashboard, and public list security settings") it returns me this error.
 
There was an unhandled exception. Please reference ID: CXZLYVCV. Error: Faraday::ClientError. Message: INVALID_FIELD: PermissionsEditPublicFilters, PermissionsCreateCustomizeReports ^ ERROR at Row:1:Column:77 No such column 'PermissionsCreateCustomizeReports' on entity 'Profile'. If you are attempting to use a custom field, be sure to append the '__c' after the custom field name. Please reference your WSDL or the describe call for the appropriate names.



User-added image
User-added image

I have created a permission set with the system permission "Two-Factor Authentication for User Interface Logins" and assigned it to the Samantha Cordero users. Here is the login history which i have used the Authenticator to authenticate the login of the user.

User-added image
What else am i missing? Any help is much appreciated.
Hi,

I'm trying to validate step 5 for the Security Specialist superbadge "Set up reporting error" and I'm geeting the following error :

Challenge Not yet complete... here's what's wrong:
The Field Sales User profile does not appear to have the correct permission for create and customize reports.

I don't understand what's wrong cause I've check all reports permissions on the Field Sales User profile.

Could you please advice ?

Thanks.
I am not sure whats the issue or i misunderstood the problem statement :

User-added image

my code :

public class StringArrayTest {
    public static List<String> generateStringArray(Integer num) {
        List<String> generateString = new List<String>();
        
        for(Integer i = 0; i <= num ; i++) {
            string formattedString = 'Test ' + i;
            generateString.add(formattedString);
        }
        System.debug(LoggingLevel.INFO, 'Formatted String for Trail Head'+generateString);
        return generateString;
    }
}

Could anyone help me understand the issue even though its silly :)
  • November 14, 2015
  • Like
  • 0
Error during taking the challenge

Even though my developer org has the Lightning App "My Data" its saying app is not available.
  • October 19, 2015
  • Like
  • 0
Hi Trailheaders!  Has anyone completed the Challenge for the "Automated Time-Based Actions with Workflow" section.

I am getting this reason: The 'Set Case to Escalated' Workflow field update action was not found

It states in the Challenge: NOTE: Since Workflow rules only fire on record save, normally you would implement this with a time-triggered workflow action...so I created it as a Time-Based action.

User-added image

Has anyone completed this Challenge successfully?



 
This question refers to the following:
https://www.salesforce.com/us/developer/docs/apexcode/Content/apex_json_jsonparser.htm

Following the example in the link above, I've added http://www.cheenath.com as a remote site.  When I execute the following snippit of the example code in the Execute Anonomous Window of the developer console:

        Http httpProtocol = new Http();
        // Create HTTP request to send.
        HttpRequest request = new HttpRequest();
        // Set the endpoint URL.
        String endpoint = 'http://www.cheenath.com/tutorial/sfdc/sample1/response.php';
        request.setEndPoint(endpoint);
        // Set the HTTP verb to GET.
        request.setMethod('GET');
        // Send the HTTP request and get the response.
        // The response is in JSON format.
        HttpResponse response = httpProtocol.send(request);
        System.debug(response.getBody());

I get back what looks like html in the return value (in the log output) from the resspone.getBody() method call.  

When I execute the full code in the parseJSONResponse method, I get the following error:

System.JSONException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at input location [1,2]

So it looks like the JSONParser is also seeing html.

What's up with this?  I get this same error on another 3rd Party site where I'm making a REST API Callout and expecting JSON as the return value.  Seems like I must be missing something fundamental in how I'm making the REST calls.  Am I looking at the wrong part of the response?  

I have also tried setting the following in the request header:
req.setHeader('content-type', 'application/json');
It doesn't make any difference in what I get back in the body.

On the other 3rd Party website, when I execute some test PHP code that makes the same REST call, I do get JSON data back, so the API seems to be working.

Thanks for any help you can give! 

How to pass values to the show method on MRUHover.getHover({!cc1.Id}.show()...So,that when i move a mouse on to the item it should display some text  on Hover.

 

 

 

<div class="" onblur="MRUHoverDetail.getHover('{!cc1.Id}').hide();"
                                       onfocus="MRUHoverDetail.getHover('{!cc1.Id}').show();"
                                       onmouseout="MRUHoverDetail.getHover('{!cc1.Id}').hide();"
                                       onmouseover="MRUHoverDetail.getHover('{!cc1.Id}').show();">

After a lot of persistence I finally was able to get repeating header and footers when rendering a Visualforce page as a PDF. The key to this is the page2PDF support of CSS3. 

 

Here is the css I came up with:

 

<style type="text/css">

@page {

@top-center {

content: element(header);

}

}

div.header {

padding: 10px;

position: running(header);

}

</style>

 

In the visualforce page I have the header setup as a div with the class name "header" the position running command pulls the content in my div and repeats it at the top of every page. The key for some reason is to put your header and footer divs at the top before you put your content on the page.

 

Here is my page

 

<apex:page renderAs="pdf">

<head>

<style type="text/css" media="print">

@page {

@top-center {

content: element(header);

}

@bottom-left {

  content: element(footer);

}

}

 

div.header {

padding: 10px;

position: running(header);

}

div.footer {

display: block;

padding: 5px;

position: running(footer);

}

 

.pagenumber:before {

content: counter(page);

}

.pagecount:before {

content: counter(pages);

}

</style>

</head>

 

<div class="header">

<div>My Header Text</div>

</div>

 

<div class="footer">

<div>Page <span class="pagenumber"/> of <span class="pagecount"/></div>

</div>

 

<div class="content">

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum nec nulla turpis. Suspendisse eget risus sit amet lectus ornare varius. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Aenean nec urna purus, adipiscing accumsan massa. Nullam in justo nulla, sed placerat mauris. In ut nunc eget libero posuere luctus. Donec vulputate sollicitudin ultrices. Nulla facilisi. Mauris in sapien arcu. Phasellus sit amet quam non mi ornare tincidunt ac quis lectus.</p>

</div>

</apex:page>

 

I cut the content text short for the purpose of this post. I am sure it will just take some more playing around.

 

Hope this helps someone avoid some late nights like I spent trying to figure this out. :smileyhappy:

 

 

Message Edited by JohnDS on 03-10-2010 07:34 PM
I'm just thinking this one out loud right now.

I was wondering if on my Visual Force page that I have created with custom objects and my desired custom layout. A Hover Detail style interface much like what salesforce uses in the sidebar for recent items when 'hover detail is enabled'.

Any points in the right direction would also be very much appreciated.

So basically I have a visual force page with all of my PageBlockTables... listing information I want in the layout that I'd like... now on some of those records I'd like to hover over the 'name' or the 'id' and trigger a "hover detail" style popup that will show some extra details that I can also choose to view / edit


Any thoughts?