UWP App deploys correctly from Remote Tools but fails when sideloaded
This app connects to a local SQLExpress Database. When deployed using remote tools it runs flawlessly but I am unable to get it to work when sideloaded. I think that a description of how the two install processes differ will point me towards a solution. I have tried creating a loopback exception but the app continues to fail at the first attempt to reach SQLEXPRESS.
Universal Windows Platform (UWP)
-
AryaDing-MSFT 2,841 Reputation points
2021-05-05T03:20:38.41+00:00 @DFlatProgrammer I have to say that it is difficult to deal with this issue based on the above information. I suggest you could use try..catch{} statement to get more exception messages, then you could provide these to us.
-
DFlatProgrammer 1 Reputation point
2021-05-05T13:35:21.577+00:00 Thanks for the response (and the sensible starting point) - The error message is "A network related or instance specific error occurred while establishing a connection to to SQL Server." Since the connection works with a deployment via Remote Debugger I'm puzzled at why it doesn't work when Sideloaded. This is a LOB app and I'm trying to establish whether I can fix the problem with Sideloading or whether there is a different deployment type that is closer to the Remote Debugger deployment.
-
DFlatProgrammer 1 Reputation point
2021-05-05T13:36:39.477+00:00 Thanks for the response (and the sensible starting point) - The error message is "A network related or instance specific error occurred while establishing a connection to to SQL Server." Since the connection works with a deployment via Remote Debugger I'm puzzled at why it doesn't work when Sideloaded. This is a LOB app and I'm trying to establish whether I can fix the problem with Sideloading or whether there is a different deployment type that is closer to the Remote Debugger deployment.
-
AryaDing-MSFT 2,841 Reputation points
2021-05-06T03:24:41.277+00:00 @DFlatProgrammer For connecting your database, the common reason is that the user doesn’t enable TCP/IP and SQL Server Browser service for SQL server. You could read the document about Trouble connecting to your database to check your configuration.
-
DFlatProgrammer 1 Reputation point
2021-05-06T13:56:03.49+00:00 Yes - I have the steps in Computer Management (configuring TCP-IP and enabling Browser) as part of my set up process - I'm checking your link to see if there is anything else in you rink that could be relevant - Again, I'm puzzled that the IDE Deployed version works, yet the Sideloaded does not..
-
AryaDing-MSFT 2,841 Reputation points
2021-05-07T09:17:44.293+00:00 @DFlatProgrammer You mentioned you have tried creating a loopback exception, could you please check whether your loopback is enabled? In addition, which version of SQL Server Express are you using?
-
DFlatProgrammer 1 Reputation point
2021-05-07T13:26:59.237+00:00 Yes - I used the command "CheckNetIsolation LoopbackExempt -s" and tested setting the loopback with both the software name and package name (no luck). The SQLExpress version is: 15.0.2000.5
My suspicion is that there is a difference in the container/sandbox that is created during the sideloading process. I'm curious if anyone knows how this process differs between Sideloading, an IDE Remote Tools deployment or a Windows Store deployment.
-
AryaDing-MSFT 2,841 Reputation points
2021-05-11T02:01:23.6+00:00 @DFlatProgrammer Could you please provide us a minimal reproducible example by OneDrive or GitHub?
-
AryaDing-MSFT 2,841 Reputation points
2021-05-11T02:02:25.11+00:00 @DFlatProgrammer We are consulting other engineers for your question, there may be some delay.
-
AryaDing-MSFT 2,841 Reputation points
2021-05-21T01:35:39.503+00:00 We need a little more information here, so please check the following questions.
For remote deployment via debugger, is this from Visual Studio? Does this mean you are deploying to a separate device? For instance a Tablet or another machine? For sideloading, again, different machine then the deployment machine?
What is the URL you are tring to connect to? Are you using a LocalHost? If you are deploying to a remote machine, such as a Tablet, are you still trying to use LocalHost? If you are, is the SQL database on that service?
If possible, you could provide a sample, which will help a lot as well.
Sign in to comment