You need to sign in to do that
Don't have an account?
Rumpa
Visualforce page to be converted to Lightning Component
I am trying to convert one Visualforce page to a lightning component. Kindly sugget best way in which this can be done for the below code.
<apex:page id="poac" standardController="MyCustomObject__c" tabStyle="MyCustomObject__c">
<apex:sectionHeader title="Message" subtitle="{!MyCustomObject__c.Name}"/>
<div id="poac_content">
<h3>Please Wait.. Processing {!MyCustomObject__c.Name}</h3>
<img class="waitingImage" src="/img/loading.gif" title="Please Wait.. Processing {!MyCustomObject__c.Name}"/>
</div> <script src="/soap/ajax/22.0/connection.js" type="text/javascript">
</script>
<script src="/soap/ajax/22.0/apex.js" type="text/javascript">
</script>
<script type="text/javascript">
sforce.connection.sessionId = "{!$Api.Session_ID}";
//var returnPath = "/{!MyCustomObject__c.id}";
var poaId = "{!MyCustomObject__c.Id}";
var result = sforce.apex.execute( "COE_Alignment_Request_Handler",
"processRequest",
{selectedID:poaId,bAdd:"FALSE"} );
if(result == 'true') {
window.location.href= "/apex/RecordRemoved"; }
else
{ var errorDisplayPanel= document.getElementById("poac_content");
errorDisplayPanel.innerHTML("<h2><b>"+result+"</b></h2>"+
"<br/><br/><a href='"+returnPath+"'> Click Here</a> to return" ); }
</script>
</apex:page>
<apex:page id="poac" standardController="MyCustomObject__c" tabStyle="MyCustomObject__c">
<apex:sectionHeader title="Message" subtitle="{!MyCustomObject__c.Name}"/>
<div id="poac_content">
<h3>Please Wait.. Processing {!MyCustomObject__c.Name}</h3>
<img class="waitingImage" src="/img/loading.gif" title="Please Wait.. Processing {!MyCustomObject__c.Name}"/>
</div> <script src="/soap/ajax/22.0/connection.js" type="text/javascript">
</script>
<script src="/soap/ajax/22.0/apex.js" type="text/javascript">
</script>
<script type="text/javascript">
sforce.connection.sessionId = "{!$Api.Session_ID}";
//var returnPath = "/{!MyCustomObject__c.id}";
var poaId = "{!MyCustomObject__c.Id}";
var result = sforce.apex.execute( "COE_Alignment_Request_Handler",
"processRequest",
{selectedID:poaId,bAdd:"FALSE"} );
if(result == 'true') {
window.location.href= "/apex/RecordRemoved"; }
else
{ var errorDisplayPanel= document.getElementById("poac_content");
errorDisplayPanel.innerHTML("<h2><b>"+result+"</b></h2>"+
"<br/><br/><a href='"+returnPath+"'> Click Here</a> to return" ); }
</script>
</apex:page>
Follow this link .
https://www.jitendrazaa.com/blog/salesforce/winter-18-automatic-styling-of-visualforce-pages-in-lightning-experience/
Thanks!
I am looking here to not just add style sheets for Lightning look ad feel of VF page.
The task is to convert the complete code and create a actual lightning component.