• Aryama Ivaturi
  • NEWBIE
  • 0 Points
  • Member since 2019

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 3
    Replies
I am downloading a csv file based on this link http://salesforceapexcodecorner.blogspot.com/2012/03/export-in-csv-and-excel-in-apex.html
But the problem is whenever I click on the Quick action button as seen in the below image I am able to download the csv.
User-added imageBut when I am trying to display text on the modal window which appears after I click on Export button, I am not able to.
User-added image
Using the below code to try and display a message saying the file is being downloaded.
<apex:page controller="exportCSV" action="{!exportToCsv}" readOnly="true" contentType="text/csv#DataAsset.csv;charset=utf8" cache="true"  >{!header}

        <apex:outputText value="Please wait, while csv file is being downloaded "/>
    <apex:repeat value="{!lstwrapper}" var="x">
     {!x.id},{!x.name},{!x.description},{!x.dataAssetType},{!x.comments}
  </apex:repeat>
</apex:page>

Please help me on this.

Hello Below is my code,
<aura:iteration items="{!v.dssList}" var="dss" indexVar="index">
                        <tr>
                            <td> 
                                {!index + 1}
                            </td>
                               <td>     
    	               <c:lwcCustomLookUp objectName="Service__c" fieldName="Name" selectRecordId="{!v.selectRecordId}" 
                       selectRecordName="{!v.selectRecordName}" iconName = "action:new_account" onselected="{!c.selectedRecords}"/> 
                               <lightning:input aura:id="customlookup" name="service" type="text" label="Service" value="{!dss.Service__c}" class="slds-hidden" />
                            </td>
                            <td>
                                <lightning:input name="isdatastored" type="checkbox" label="Is Data Stored" value="{!dss.Is_Data_Stored__c}" />
                            </td>
                            <td>
                                <lightning:input name="isdataprocessed" type="checkbox" label="Is Data Processed" value="{!dss.Is_Data_Processed__c}" />
                            </td>
                            <td>
                                <lightning:input name="isdatatransmitted" type="checkbox" label="Is Data Transmitted" value="{!dss.Is_Data_Transmitted__c}" />
                            </td>
                        
                            <td>
                                <a onclick="{!c.removeRowDSS}" data-record="{!index}">
                                    <lightning:icon iconName="utility:delete" size="small" alternativeText="Delete"/>
                                    <span class="slds-assistive-text">Delete</span>
                                </a>
                            </td> 
                        </tr>
                    </aura:iteration>



I need to pass the index value from aura iteration to custom lwc component so that I can set it uniquely . Currently for lightning input I have aura:id as customlookup. But I need to have it dynamically set so the value from custom lookup lwc is assigned to lightning input.
Below is my controller function for customlookup
selectedRecords : function(component, event, helper) {
        var selectRecName = event.getParam('selectName');
        var selectRecId = event.getParam('currentRecId');
        if(selectRecName != undefined) {
            component.set("v.selectRecordName", selectRecName);
            component.set("v.selectRecordId", selectRecId);
            alert(component);
           // var a = event.getSource();
            //var id = a.getLocalId();
            //alert(id);
            //component.find("").set("v.value", selectRecId);
            component.find("customlookup").set("v.value", selectRecId);
        }



Need help me on this.
Hello,
Can we create a custom app through apex code? I see that we can create custom objects and fields through apex code. Similarly, can we create a custom app through salesforce? Just an app called Demo and add custom tabs to it through apex code.
I am downloading a csv file based on this link http://salesforceapexcodecorner.blogspot.com/2012/03/export-in-csv-and-excel-in-apex.html
But the problem is whenever I click on the Quick action button as seen in the below image I am able to download the csv.
User-added imageBut when I am trying to display text on the modal window which appears after I click on Export button, I am not able to.
User-added image
Using the below code to try and display a message saying the file is being downloaded.
<apex:page controller="exportCSV" action="{!exportToCsv}" readOnly="true" contentType="text/csv#DataAsset.csv;charset=utf8" cache="true"  >{!header}

        <apex:outputText value="Please wait, while csv file is being downloaded "/>
    <apex:repeat value="{!lstwrapper}" var="x">
     {!x.id},{!x.name},{!x.description},{!x.dataAssetType},{!x.comments}
  </apex:repeat>
</apex:page>

Please help me on this.

Hello Below is my code,
<aura:iteration items="{!v.dssList}" var="dss" indexVar="index">
                        <tr>
                            <td> 
                                {!index + 1}
                            </td>
                               <td>     
    	               <c:lwcCustomLookUp objectName="Service__c" fieldName="Name" selectRecordId="{!v.selectRecordId}" 
                       selectRecordName="{!v.selectRecordName}" iconName = "action:new_account" onselected="{!c.selectedRecords}"/> 
                               <lightning:input aura:id="customlookup" name="service" type="text" label="Service" value="{!dss.Service__c}" class="slds-hidden" />
                            </td>
                            <td>
                                <lightning:input name="isdatastored" type="checkbox" label="Is Data Stored" value="{!dss.Is_Data_Stored__c}" />
                            </td>
                            <td>
                                <lightning:input name="isdataprocessed" type="checkbox" label="Is Data Processed" value="{!dss.Is_Data_Processed__c}" />
                            </td>
                            <td>
                                <lightning:input name="isdatatransmitted" type="checkbox" label="Is Data Transmitted" value="{!dss.Is_Data_Transmitted__c}" />
                            </td>
                        
                            <td>
                                <a onclick="{!c.removeRowDSS}" data-record="{!index}">
                                    <lightning:icon iconName="utility:delete" size="small" alternativeText="Delete"/>
                                    <span class="slds-assistive-text">Delete</span>
                                </a>
                            </td> 
                        </tr>
                    </aura:iteration>



I need to pass the index value from aura iteration to custom lwc component so that I can set it uniquely . Currently for lightning input I have aura:id as customlookup. But I need to have it dynamically set so the value from custom lookup lwc is assigned to lightning input.
Below is my controller function for customlookup
selectedRecords : function(component, event, helper) {
        var selectRecName = event.getParam('selectName');
        var selectRecId = event.getParam('currentRecId');
        if(selectRecName != undefined) {
            component.set("v.selectRecordName", selectRecName);
            component.set("v.selectRecordId", selectRecId);
            alert(component);
           // var a = event.getSource();
            //var id = a.getLocalId();
            //alert(id);
            //component.find("").set("v.value", selectRecId);
            component.find("customlookup").set("v.value", selectRecId);
        }



Need help me on this.
Hello,
Can we create a custom app through apex code? I see that we can create custom objects and fields through apex code. Similarly, can we create a custom app through salesforce? Just an app called Demo and add custom tabs to it through apex code.