sp-dev-docs icon indicating copy to clipboard operation
sp-dev-docs copied to clipboard

Open external URLs with SPFX Extension listview command set dialog

Open kspranesh opened this issue 8 years ago • 2 comments

Question : How to enable list view commandset to open an external URL when clicked.

Requirement : I have a need to open an external URL and pass list item properties to it as additional parameters. I have a command set extension developed and in the onExecute event i am capturing the item properties which i need to pass as parameter and open a modal dialog to an external URL. I am not finding direct way to call window.Showmodaldialog within the code. Do i have to create a seperate dialog object from BaseDialog and code there to open dialog ?

public onExecute(event: IListViewCommandSetExecuteEventParameters): void { switch (event.itemId) { case 'COMMAND_1': const filePath: string = event.selectedRows[0].getValueByName("ServerRedirectedEmbedUrl"); {Open showdialog here } // Dialog.alert(${this.properties.sampleTextOne}); break;

kspranesh avatar Mar 21 '18 21:03 kspranesh

I am wanting to do something similar and open an existing dialog in SharePoint. Anyone done this before?

mulduni avatar Sep 28 '18 15:09 mulduni

This issue is being closed as part of an issue list cleanup project. Issues with no activity in the past 6 months that aren't tracked by engineering as bugs were closed as part of this inititive. If this is still an issue, please follow the steps outlined to re-open the issue.

msft-github-bot avatar Jan 22 '20 21:01 msft-github-bot