force-app/main/default/lwc/lexPreviewPDF/lexPreviewPDF.js
@@ -4,18 +4,17 @@ export default class lexPreviewPDF extends LightningElement { @api recordId; IsLoading=true; @wire(CurrentPageReference) getStateParameters(currentPageReference){ if(currentPageReference){ console.log(currentPageReference); const IdValue=currentPageReference.state.recordId; if(IdValue){ let str=`${IdValue}`; this.recordId=str; console.log("recordId="+str); } } } @@ -23,6 +22,7 @@ connectedCallback(){ this.PreviewPDF().then(res=>{ this.IsLoading=false; this.dispatchEvent(new CloseActionScreenEvent()); }); }