Copy Link Button

  • 8 February 2017
  • 8 replies
  • 45 views

Badge +3

Hi Folks,

    I'm looking to implement a button that copies the link to a nintex form.

Has anyone done this before?

To Clarify My question:

I'm looking for direction on how to create a button that copies the link of a nintex form.

-The form has been created and saved

-Upon opening the form, a button appears at the top that allows the user to copy the link of that form.

- I can implement the logic on how to hide the button for new forms, looking for help with the javascript(may  be)


8 replies

Userlevel 5
Badge +14

google returns ~6 milion answers to your question. hard to pick only one to answer your question.

(joking happy.png)

if you expect any sensefull answer you have to describe your problem clearly and in as much details as possible.

Badge +16

I assume you want a button on the nintex form itself that copies the URL of the current item (form) ready to paste it?

Badge +3

Yes, that's exactly what I looking for.

I understand that the user may have to save this form first for this to be possible. I just wanted to eliminate the possibility of people copying incomplete link

Badge +16

I assume you'll need script to do this and that's not my area of expertise I'm afraid - just wanted to clarify the question - perhaps my fellow BRG member ‌ might have a cool trick up his sleeve?! 

Userlevel 7
Badge +17

I'm not able to test this out at the moment, but this could lead in a good direction. If it does then we can post the steps to produce instead of a link out. You would need to add a JavaScript button that calls the functions in the article. 

html - Click button copy to clipboard using jQuery - Stack Overflow 

Userlevel 4
Badge +7

The easiest, and safest way, is to add the button to your form with a Client Click of CopyURL()

198574_pastedImage_1.png

Then add this code to the Custom JavaScript in form settings

function CopyURL(){
var text = window.location.href;
window.prompt("Copy to clipboard: Ctrl+C, Enter", text);
}‍‍‍‍

The user will be displayed a prompt box with the URL highlighted and can ctrl+c and close the window.

I know there is an additional step but I understand it is not best practice to add to the clipboard directly.

This will give you the correct functionality though.

Let me know how you get on

Badge +3

Thanks! Worked!

Userlevel 7
Badge +17

Very nice!

Reply