+ Start a Discussion
Vinay_guptaVinay_gupta 

override standand new button to vf page in lightning

Hi All,

I want to navigate a new button to VF page navigation in Lightning. I think here we need to create a component but can you please help me with a component creation and navigating to VF page.

Regards,
Vinay
Gulafsha MohammedGulafsha Mohammed
Hi,

Component:
 
<aura:component implements="force:appHostable,force:lightningQuickActionWithoutHeader,flexipage:availableForAllPageTypes" access="global" >
        <ui:button label="navigateToURL" press="{!c.gotoURL}" />
</aura:component>

Controller:
 
gotoURL : function(component, event, helper) {
    var urlEvent = $A.get("e.force:navigateToURL");
    urlEvent.setParams({
        "url":"vfpage url"
    });
    urlEvent.fire(); }

If this has solved yor query please mark this as best answer.

Regards,
Gulafsha