Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello ,
I am trying to connect with QlikSense through .Net SDK , My qliksense server is hosted in my dedicated server , i am able to access from my browser . When i connect them from the .Net SDK code , it throws the following error :
I would like to paste my code for your view :
ILocation location = Qlik.Engine.Location.FromUri(new Uri("http://myserverip:port/"));
location.AsDirectConnectionToPersonalEdition();
using (IHub hub = location.Hub())
{
string value = hub.ProductVersion();
}
can you please help to fix this issue .
Thanks for your support.
AsDirectConnectionToPersonalEdition indicates you are connecting to a Qlik Sense Desktop instance and not a Server.
You probably wanna connect using the NTML methods instead if you want to authenticate against the Server
Thanks Alex ,
I have constructed the code as per your suggestion , please find the code below :
var uri = new Uri("https://myQlikSenseServer.myDomain.com:port");
ILocation location = Qlik.Engine.Location.FromUri(uri);
location.AsNtlmUserViaProxy(proxyUsesSsl:true);
The same error occurs again.
I have some clarifications in my mind , i would like to bring to your notice . they are :
1. Is it possible authenticate qliksense server using the code itself , i don't want the page to ask the Username and Password ?, and where to hard code the Credentials ?
2. do i need to give any permissions to give access to my server , in order to connect from the .Net SDK code ?
3. i have download the sample application given by the Community (PublicExamples) , using this code , i am trying to connect my server , the same error occurs again and again .
Please give me a solutions for this problems .
Thanks .
Do you have a valid certificate for the proxy you're connecting to?
If not you can test to override certificate validation using:
location.AsNtlmUserViaProxy(certificateValidation:false);