
“Sim-Sim, open up!”, Or how to open a link via RemoteApp
More and more, we began to bring our programs to the clouds. Whether it’s good or bad, we won’t talk about it, but today we’ll talk a little about the situation when it is necessary to dock local programs with the cloud: in the context of our Docsvision EDS and any email client installed locally on the user PC. Imagine a task: open a link to a Docsvision “card”, which was sent by mail to a user in an email client installed locally on his computer. Having studied the issue, having analyzed the experience of our partners, we have found a solution that we want to share with you.
The main client software in Docsvision is Navigator, which can be published as Remote App. There can be various reasons for this: for example, a weak channel from a remote unit to the Docsvision server. Cloudy, fast for the user, convenient for the admin. But what happens in the case of the problem described above, when you need to open the link to the "card" from the mail client installed locally on the computer by the user.
Let's explain a little what happens in such a default configuration. The user receives an email with a link to the Docsvision object, tries to follow it, he has a locally installed browser and ... here the problems begin, because the link does not open for him due to the fact that the Docsvision server is not available. The user is indignant and scribbles applications to the IT service. Recently, the question “how to solve this problem?” Has been sounded more often from system administrators.
The essence of our decision is as follows
A link to an object in Docsvision is formed in a specific form. When this link is called on the client computer, a script is launched that opens RemoteApp and converts it into a standard link to the Docsvision object, which is opened by the default browser in RemoteApp. Thus, we run Docsvision Navigator on the remote desktop.
Of course, this solution does not claim to be the only right one, but we are sure that it is working and is used in solutions in which there are more than 4,000 active users.
We will share it in the form of step-by-step instructions.
Step-by-step setup
1. Create a VBS script with content.
2. We publish the created VBS script as RemoteApp on the server, for example, with the name "docsvision5-link".
Go to RemoteApp Manager and select “Add Remote Programs”.

In the opened “RemoteApp Wizard”, following the instructions, we publish the VBS script





3. We give the published application “docsvision5-link” permission to execute all command line commands.


4. Create an RDP file for the docsvision5-link application in the Remote App Wizard (an example of an RDP file is dv5link.rdp).




5. We distribute the conscious Rdp file to client workstations.
6. On the client computer, create the dv5term registry branch using a file with the .reg extension, which contains entries:
7. We change the formation of the link that the server forms on the cards, dv5term: //server.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}
What will happen with these settings: The
user clicks on link:
dv5term: //serverRDP.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}

The command associated with the registry is executed:
those. \\ serverRDP.docsvision.com \ DocsVision \ dv5link.rdp with the parameter passed in the form of a full URL A

script with the same parameter is
called : \\ serverRDP.docsvision.com \ C $ \ script \ ie5.vbs% 1

This script:

converts the parameter:
dv5term: //serverRDP.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}
to
serverRDP.docsvision.com/DocsVision/?CardID= {1007DDE2-76E0-E511 A0D3C1063571}
regular replacement and makes a call
Those. tries to execute the command in the standard way for the system, or more precisely, it will try to open the serverRDP.docsvision.com/DocsVision/?CardID= {1007DDE2-76E0-E511-80CA-A0D3C1063571} link on the terminal server with the browser, we’ll
repeat this decision does not claim to be the only right one. Perhaps you have some other solutions to this problem?
We will be happy to share it!
Kirill Khokhlov, Senior Consultant, DoksVision.
The main client software in Docsvision is Navigator, which can be published as Remote App. There can be various reasons for this: for example, a weak channel from a remote unit to the Docsvision server. Cloudy, fast for the user, convenient for the admin. But what happens in the case of the problem described above, when you need to open the link to the "card" from the mail client installed locally on the computer by the user.
Let's explain a little what happens in such a default configuration. The user receives an email with a link to the Docsvision object, tries to follow it, he has a locally installed browser and ... here the problems begin, because the link does not open for him due to the fact that the Docsvision server is not available. The user is indignant and scribbles applications to the IT service. Recently, the question “how to solve this problem?” Has been sounded more often from system administrators.
The essence of our decision is as follows
A link to an object in Docsvision is formed in a specific form. When this link is called on the client computer, a script is launched that opens RemoteApp and converts it into a standard link to the Docsvision object, which is opened by the default browser in RemoteApp. Thus, we run Docsvision Navigator on the remote desktop.
Of course, this solution does not claim to be the only right one, but we are sure that it is working and is used in solutions in which there are more than 4,000 active users.
We will share it in the form of step-by-step instructions.
Step-by-step setup
1. Create a VBS script with content.
On Error Resume Next
Dim WshShell
Set WshShell = CreateObject("WScript.Shell")
Dim regEx
if WScript.Arguments.count >0 then
Arg = WScript.Arguments.Item(0)
Set regEx = New RegExp
regEx.Pattern = "^dv5term://(.*)"
regEx.IgnoreCase = True
arg = regEx.Replace(arg, "$1")
WshShell.Run "http://" & arg
end if
2. We publish the created VBS script as RemoteApp on the server, for example, with the name "docsvision5-link".
Go to RemoteApp Manager and select “Add Remote Programs”.

In the opened “RemoteApp Wizard”, following the instructions, we publish the VBS script





3. We give the published application “docsvision5-link” permission to execute all command line commands.


4. Create an RDP file for the docsvision5-link application in the Remote App Wizard (an example of an RDP file is dv5link.rdp).




5. We distribute the conscious Rdp file to client workstations.
6. On the client computer, create the dv5term registry branch using a file with the .reg extension, which contains entries:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\dv5term]
@="URL:dv5term Protocol"
"URL Protocol"=""
[HKEY_CLASSES_ROOT\dv5term\shell]
@=""
[HKEY_CLASSES_ROOT\dv5term\shell\open]
@=""
[HKEY_CLASSES_ROOT\dv5term\shell\open\command]
@="\"mstsc\" /remotecmdline:\"%1\" \"\\\\serverRDP\\DocsVision\\dv5link.rdp\""
7. We change the formation of the link that the server forms on the cards, dv5term: //server.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}
What will happen with these settings: The
user clicks on link:
dv5term: //serverRDP.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}

The command associated with the registry is executed:
"mstsc" /remotecmdline:"%1" "\\serverRDP.docsvision.com\DocsVision\dv5link.rdp"
those. \\ serverRDP.docsvision.com \ DocsVision \ dv5link.rdp with the parameter passed in the form of a full URL A

script with the same parameter is
called : \\ serverRDP.docsvision.com \ C $ \ script \ ie5.vbs% 1

This script:
On Error Resume Next
Dim WshShell
Set WshShell = CreateObject("WScript.Shell")
Dim regEx
if WScript.Arguments.count >0 then
Arg = WScript.Arguments.Item(0)
Set regEx = New RegExp
regEx.Pattern = "^dv5term://(.*)"
regEx.IgnoreCase = True
arg = regEx.Replace(arg, "$1")
WshShell.Run "http://" & arg
end if

converts the parameter:
dv5term: //serverRDP.docsvision.com/DocsVision/? CardID = {1007DDE2-76E0-E511-80CA-A0D3C1063571}
to
serverRDP.docsvision.com/DocsVision/?CardID= {1007DDE2-76E0-E511 A0D3C1063571}
regular replacement and makes a call
Set WshShell = CreateObject("WScript.Shell")
WshShell.Run http://serverRDP.docsvision.com/DocsVision/?CardID={1007DDE2-76E0-E511-80CA-A0D3C1063571}
Those. tries to execute the command in the standard way for the system, or more precisely, it will try to open the serverRDP.docsvision.com/DocsVision/?CardID= {1007DDE2-76E0-E511-80CA-A0D3C1063571} link on the terminal server with the browser, we’ll
repeat this decision does not claim to be the only right one. Perhaps you have some other solutions to this problem?
We will be happy to share it!
Kirill Khokhlov, Senior Consultant, DoksVision.