• $Abhi$
  • NEWBIE
  • 0 Points
  • Member since 2011
  • Team Lead
  • Persistent Systems Limited

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 10
    Questions
  • 8
    Replies
Problem statement:
When we try to access the 'window.opener.$A' property of lightning component present in the parent from a javascript snippet present in a child window (Visual force page) we get the error 'Permission denied to access property "$A"'

Task:
We intend to open a child window on click of a button present in a lightning component.  The child window would present the user with certain selectable data. Once the user selects certain row, and clicks submit, the row data(obtained by the child window using callouts) has to be returned to the parent lightning component/App which opened the child window(containing VF page).

Activities completed:
  • We created a 'Application' level global access event named as 'ICDCodeSelected' (Syntax for which is as follows), which we want to utilize to pass data from child window to parent window's lightning component.
<aura:event type="APPLICATION" description="Event template" access="global">
    <aura:attribute name='CODE' type='String'/>
    <aura:attribute name='DESCRIPTION' type='String'/>
</aura:event>
  • As per mentioned in SF documentation(https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/events_external.htm), we have added following code snippet to our Visualforce Page javascript which is as follows:
var myExternalEvent;
if(window.opener.$A && (myExternalEvent = window.opener.$A.get("e.c:ICDCodeSelected"))) {
    myExternalEvent.setParams({CODE:'M84.3',DESCRIPTION:'Home visit for the evaluation and management of a new pat..'});
    myExternalEvent.fire();
}
Note :
Please note that the error appears for 'window.opener.$A' only, when we include the lightning dependency application/component inside the VF page (child window) using lightning out, we can access the $A component ad hence can get the Event to fire it, but it fires only in the context of the child window, and their is not update on the parent lightning page.

Your inputs/comments/suggestions on the above issue resolutions would be pretty helpful for us.

Thanks

Hi,

 

I have created a approval process on the 'Opportu nity' object.When a opportunity record is submitted for approval, a new post is added on the chatter wall.For this post I am not getting an email alert from chatter..

For additional info, I am getting approval mails, according to the template specified in the approval process, but I want to get the chatter email alert for new approval process post on the chatter.

Any pointers on the issue, caan be of great help.

 

  • February 25, 2013
  • Like
  • 0

Hi,

I have a requirement, under which I want to turn off the compatibility mode of IE9, so that when my visualforce page loads, the page displays in IE9 with compatibility mode off.

I investigated on achieving the task, and found that the following tag could be used inside the HTML header to turn off the compatibility mode

 

TAG :<head><meta http-equiv="X-UA-Compatible" content="IE=edge"/></head>

 

But the problem is,

1)The tag is added to the header only if the 'showHeader' for the VF page is false

2)Even after adding the tag to the HTML header, by turning the 'showHeader' property of the page to 'true' the compatibility mode is not turned off for IE9

 

Any pointers on this issue would be of great help.

 

  • November 29, 2012
  • Like
  • 0

Hi,

 

I have a APEX class that implements the Database.batchable Interface.As per my knowledge the batch jobs run in system context, and are not limited by the sharing rules.

I wanted to know that, if a class implements the Database.batchable Interface then, is the constructor of this class run in system context or or not.

Any pointers on the same would be of great help.

 

Thanks

  • November 15, 2012
  • Like
  • 0

Hi.

 

I read the documentation for the ''runes'' method, and found that the method 'runes' can only be used in a test method.

 

I wanted to implement the same 'runes' functionality in the normal APEX class. That is , I wanted to execute certain block of code according to the user context specifid by me in the code.

 

So is this possible in normal APEX class? if yes then how can this be implemented.

 

Any pointers regarding this issue would be of great help.

 

 

  • October 04, 2012
  • Like
  • 0

Hi,

 

I have encountered the Error 'sObject type Organization is not supported' .I investigated and found that the profile must have 'View All Data' permission to access the object.

 

I want to understand that is it possible to avoid the error on the 'Organization' object without giving the 'View All Data' permission to the profile or without removing the 'with Sharing' keyword from the class for which the error arises

 

Any pointers on the same would be of great help. Thanks in Advance.

  • August 08, 2012
  • Like
  • 0

I want to develop sample applications using REST API and C#.net platform, Is there a sample C# applicaiton with code available online that does so or how can I do it.

Any pointers or links regarding the same could be of great help.

Hi,

I wanted to filter the Salesforce report on basis of date ( suppose created date), so that the manual filtering through 'Time Frame' legend be avoided. I thought of using 'bucket filter' to accomplish the task but found that bucket filters cannot be applied for time,time/date formats.

So the question is that, is their any other way to accomplish the grouping of records in Salesforce Reports on basis of date without using the Salesforce 'Time Frame' legend ?

Any pointers on the same would be of great help. Thanks in advance.

 

Hi,

I am trying to generate a custom report that would display opportunities in stage Value Proposition  that have advanced(Their stage has increased in comparison to their prior stage.) or regressed (Their stage has decreased in comparison to their prior stage) for a given time interval.

I found a formula to obtain the regressed opportunities as follows:

 

OR(Amount < PRIORVALUE(Amount), Probability < PRIORVALUE(Probability), CloseDate > PRIORVALUE(CloseDate),CASE( StageName ,
"Prospecting",1,
"Qualification",2,
"Needs Analysis",3,
"Value Proposition",4,
"Id. Decision Makers",5,
"Perception Analysis",6,
"Proposal/Price Quote",7,
"Negotiation/Review",8,
"Closed Won",9,
"Closed Lost",9,0)
<
CASE(PRIORVALUE(StageName) ,
"Prospecting",1,
"Qualification",2,
"Needs Analysis",3,
"Value Proposition",4,
"Id. Decision Makers",5,
"Perception Analysis",6,
"Proposal/Price Quote",7,
"Negotiation/Review",8,
"Closed Won",9,
"Closed Lost",9,0))
 
 I used this formula in the add formula section in Left side bar in a Summary report type, but it doesn't allow saving this formula.
Since this is not working so any pointers to achieve the above mentioned task would be of great help.
Thanks in advance.
  • April 19, 2012
  • Like
  • 0

Hi,

I wanted to create reports on Opportunities in a specific stage that have advanced or regressed according to the fiscal period.

Any pointers on achieving the same would be of great help.

Thanks in advance.

  • April 18, 2012
  • Like
  • 0
Hello,

i have a problem with my lightning component. Yesterday all input element had shown up. But today they dont. HTML is generated correctly.

What is the problem?
 
<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId,forceCommunity:availableForAllPageTypes,lightning:actionOverride,force:lightningQuickActionWithoutHeader" access="global" controller="CtrlCreateAttendeeContact">
    <aura:handler name="init" value="{!this}" action="{!c.doInit}"/>
    <aura:attribute name="contact" type="Contact" 
                    default="{ 'sobjectType': 'Contact' }"/>
    <aura:attribute name="registrationId" type="Id" />
    <div role="dialog" tabindex="-1" aria-labelledby="header99" class="slds-modal">
            <div class="slds-modal__container">
                    <ui:outputText class="slds-hide" aura:id="attendeeRecordTypeId" value="{!v.contact.RecordTypeId}"/>
                    <ui:outputText class="slds-hide" aura:id="eventregistrationId" value="{!v.registrationId}"/>
                    <div class="slds-select_container">
                        <ui:inputSelect aura:id="conSalutation" class="slds-select"  change="{!c.onPicklistChange}" value="{!v.contact.Salutation}"/>
                    </div>
                    <lightning:input value="{!v.contact.FirstName}" name="FirstName" label="Firstname" required="true"/>
                    <lightning:input value="{!v.contact.LastName}" name="LastName" label="Lastname" required="true"/>
                    <lightning:input type="email" value="{!v.contact.Email}" label="email" required="true"/>
                    <div class="slds-modal__footer">
                        <lightning:button class="slds-button slds-button--brand" label="save" onclick="{!c.createContact}"/>
                    </div>
        </div>
    </div>
</aura:component>

thanks for any advise.
Peter

 
Problem statement:
When we try to access the 'window.opener.$A' property of lightning component present in the parent from a javascript snippet present in a child window (Visual force page) we get the error 'Permission denied to access property "$A"'

Task:
We intend to open a child window on click of a button present in a lightning component.  The child window would present the user with certain selectable data. Once the user selects certain row, and clicks submit, the row data(obtained by the child window using callouts) has to be returned to the parent lightning component/App which opened the child window(containing VF page).

Activities completed:
  • We created a 'Application' level global access event named as 'ICDCodeSelected' (Syntax for which is as follows), which we want to utilize to pass data from child window to parent window's lightning component.
<aura:event type="APPLICATION" description="Event template" access="global">
    <aura:attribute name='CODE' type='String'/>
    <aura:attribute name='DESCRIPTION' type='String'/>
</aura:event>
  • As per mentioned in SF documentation(https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/events_external.htm), we have added following code snippet to our Visualforce Page javascript which is as follows:
var myExternalEvent;
if(window.opener.$A && (myExternalEvent = window.opener.$A.get("e.c:ICDCodeSelected"))) {
    myExternalEvent.setParams({CODE:'M84.3',DESCRIPTION:'Home visit for the evaluation and management of a new pat..'});
    myExternalEvent.fire();
}
Note :
Please note that the error appears for 'window.opener.$A' only, when we include the lightning dependency application/component inside the VF page (child window) using lightning out, we can access the $A component ad hence can get the Event to fire it, but it fires only in the context of the child window, and their is not update on the parent lightning page.

Your inputs/comments/suggestions on the above issue resolutions would be pretty helpful for us.

Thanks

Hi.

 

I read the documentation for the ''runes'' method, and found that the method 'runes' can only be used in a test method.

 

I wanted to implement the same 'runes' functionality in the normal APEX class. That is , I wanted to execute certain block of code according to the user context specifid by me in the code.

 

So is this possible in normal APEX class? if yes then how can this be implemented.

 

Any pointers regarding this issue would be of great help.

 

 

  • October 04, 2012
  • Like
  • 0

Hi,

 

I have encountered the Error 'sObject type Organization is not supported' .I investigated and found that the profile must have 'View All Data' permission to access the object.

 

I want to understand that is it possible to avoid the error on the 'Organization' object without giving the 'View All Data' permission to the profile or without removing the 'with Sharing' keyword from the class for which the error arises

 

Any pointers on the same would be of great help. Thanks in Advance.

  • August 08, 2012
  • Like
  • 0

hi,

 

just like to ask if am i missing some items when doing the changeset deployment?

im having an error in deploying a report having a bucketfield

 

thanks in advance,

mark

  • May 02, 2012
  • Like
  • 0

Hi,

I wanted to create reports on Opportunities in a specific stage that have advanced or regressed according to the fiscal period.

Any pointers on achieving the same would be of great help.

Thanks in advance.

  • April 18, 2012
  • Like
  • 0