Dynamic link to file

Hey,

I would like to add a link icon in a table on a screen so that if you click on that icon you get redirected to the folder on a server.

So lets say I'm storing informations of a measurement in a database. And I also store in one column the path to the folder, where the files of the measurement lay. The path would look like "//IP-ADRESS/Folder/Folder1".

I tried it this way: https://www.outsystems.com/forums/discussion/65637/make-dynamic-link-to-external-website/

but the link ends up like: "https://dev-outsystems.com///IP-ADRESS/Folder/Folder1"

How do I get rid of that prefix in the URL?

Hi Markus,

Please find attached the modified OML, with an example solution to your need.

Hope it helps.

Best regards,

Paulo Moreira

dynamic link.oml

Hi! 

Have you tried the functions in the HTTPRequestHandler? 

I would try GetEntryURL  or MakeAbsoluteURL !

Just an idea. 

Regards

Graça

Hi!

Where do I find that HTTPRequestHandler?

I can't find any documentation.

In Service Studio , menu item 

 Module > Manage Dependencies

you will find it in the list of modules. 

Found it, but didn't manage to get it to work. I also tried some file handlers. But also the same. I did a workaround, where I open a popup which displays the link. So I can copy it and open it.

Hi Markus,

Do you think it's possible for you to send us a small example of the isue you're experiencing? It would help to have a small example to better come up with a solution.

Thank you very much in advance.

Best regards,

Paulo Moreira

I've created a small example. In the table there is a onclick action for the folder symbol. If you click on that symbol I want to open the url destination from the database column "link".

At the moment I'm opening a popup in my report that displays the url for copy and paste. But that's not really suitable.

dynamic link.oml

Hi Markus,

Please find attached the modified OML, with an example solution to your need.

Hope it helps.

Best regards,

Paulo Moreira

dynamic link.oml

Hey Paulo,

that's working! I always tried to add a link to that icon with "RedirectToURL" but you have to add the ExternalURL right into the Mainflow by clicking on the Mainflow Icon under Interface. 

So 2 additional hints for those who find this:

- your link to a file should look like this: file://///c:/daten. With the 5 slashes it works.

- If you are using chrome, the link is blocked, you have to install an addon that allows links to your filesystem: Enable local file links



Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.