Qlik Community

Integration, Extension & APIs

Discussion board where members can learn more about Integration, Extensions and API’s for Qlik Sense.

Announcements
Support Case Portal has moved to Qlik Community! Read the FAQs to start exploring Support resources.
cancel
Showing results for 
Search instead for 
Did you mean: 
VictorVelasquez96
Contributor
Contributor

Qlik sense .NET SDK (C#) to connect to QlikSense using a web proxy server

Hi,

i've a problem with my app.

it works with every server but there is one that need to connect to vpn and install the proxy (in the windows setting).

 

My code for connection:

public static ILocation DirectRemoteServer(string domain, string user, string password, string machineDomain)
{

var uri = new Uri(domain);
ILocation location = Qlik.Engine.Location.FromUri(uri);

location.AsNtlmUserViaProxy(proxyUsesSsl: uri.Scheme.Equals(Uri.UriSchemeHttps),loginCredentials: new NetworkCredential(user,password,machineDomain),certificateValidation: false);

return location;
}

 

In the app.config file:

<system.net>
<defaultProxy enabled="true">
<proxy scriptLocation="http://nome/" />
</defaultProxy>
</system.net>

 

The response:

System.Exception: 'Websocket closed unexpectedly (EndpointUnavailable): '

 

Someone has suggetions?

Thanks,

Victor

1 Reply
yko
Employee
Employee

I'm not sure I understand what you mean by "install the proxy", but you could add a debug console to your code and see if you get some information regarding what goes on from there. Something like this:

var location = DirectRemoteServer(...);
using (new DebugConsole())
using (var hub = location.Hub())
{
    Console.WriteLine(hub.EngineVersion().ComponentVersion);
}