I have developed a C# application with a SQL Server database. When I try to publish the application to test it >> it works correctly on my machine (that include the database in SQL Server data folder) >> but when I move that published app to another machine it doesn't work.
An Attempet to Attach an auto-named database for file C:\Program Files (x86)\Microsoft SQL Server\MSSQL.1\MSSQL\Data\KBank.mdf Failed, a database with the same name exists or specified file cannot be opened, or its location on UNC share
Your application can not find the database file that is specified in the connection string talk less of connection to it. This is because the database is auto-named rather than a data file. All you need to do is to make the database an attached data file to the package so that when deployed the database will go along with it.To do this, on visual studio IDE, on the publish tab chose "Application Files" change the Publish status of the database file from "Include Auto" to "Data File", then validate. This will add the database file to ur application upon publish and deployment.To access project property,1)With Visual studio 2010/2012 - Click Project Menu -> Properties -->
I have resolved my problem > the problem was that i didn't add a Local Database to my project solution.. so when i try the project on another machine the application couldn't find the specified connection sting that have the path:
I was wondering if it's possible to utilize the .pubxml publish profile in .Net Core projects when publishing an MSIX packaging project. Specifically, I would like to publish the app self-contained, so I do not have to depend on the .Net Core runtime being installed. I've posted a question to StackOverflow here:
-do-i-use-a-windows-application-packaging-project-in...
The Windows 10 binary contains platform code, application code (JavaScript) and other resources. Platform code is secured from disassembly when the application is built in Release mode. Windows internally uses native .Net Compilation in release mode and classic .net compilation in debug mode.
To hide the JavaScript code, Volt MX Iris needs to pass hideSourceCode property with True as value to the build process. You have to set the flag so that the build process ensures the application is hidden from dis-assembly.
Windows 10 allows a single application binary to be deployed and run on multiple device families such as mobile, desktop/tablet, Xbox and IoT. You can choose the binary to be run on any Windows 10 device (of any device family) or you can restrict the binary to be allowed to run on particular device family/families only. Currently, the allowed device families are:
The deployable component for Windows 10 tablet/desktop is an APPX file. If an application is built using Volt MX Iris on Windows 10, the application creates an APPX file with the name .appx in target build output folders \temp\\build\windows10\windows10\VoltMXApp\x86x64ARM\.appx.
If an application is built using Volt MX Iris on Windows 7 or Windows 8/8.1 system, a zip file is created with all the required information with name voltmxwindows10.zip in the build output folder. The file can help you to create an APPX file.
On a separate Windows 10 system with development configuration, copy the above output folder (through a USB or pen drive). Ensure the extracted folder is not a system folder such as Program Files or Windows. The folder has the following batch file:
You can use PackageFromZipFile.bat with either of the following options to deploy the application on to a x86/x64/ARM-based Windows 10 machine. Ensure APPX file is created in the same folder. The batch file deploys the application when the APPX file is created.
Do not use Volt MX Developer certificate to sign the customer application. The Volt MX Developer certificate should be used only during the application development. When submitting the application to the store, you can use your own certificate to sign the APPX package.
To use the existing certificate file, use the Certificate file section, and select the required PFX certificate file. Ensure the publisher name of the existing certificate matches the publisher name provided previously. The build fails if the publisher names does not match.
Debug mode - To help you identify and fix errors, Volt MX Iris emits the complete symbolic debug information . To lessen the amount of time necessary to complete the build, the build is not optimized for code execution, so it may tend to execute slower than a build optimized for release. Also, the inclusion of the symbolic debug information causes the final executable to be larger than a release build.
Test Mode - To help you identify and fix errors, Volt MX Iris provides the ability to Test the application on the device or an emulator. When you build an app using the Test Mode, you can leverage the Jasmine testing framework of Volt MX Iris to thoroughly test your app and ensure your application is errors free. You can run jasmine test cases, test suites and test plans by building an app using the Test mode.
You can open the solution folder, and make changes to the app manifest file. You must place the updated manifest file in the Resources folder so that the build process picks and uses for application build.
Note: After you place the new manifest file in resources, any change done in Volt MX Iris Application properties page will not be considered as the files provided by user replace all Volt MX Iris Application Properties page.
This guide shows how to set up your SDK development environment to build and deploy Cordova apps Windows 10 (Universal Windows Platform [= UWP], formerly known as Universal App Platform [= UAP]), Windows 8.1 and Windows Phone 8.1. It shows how to use either shell tools to generate and build apps, or the cross-platform Cordova CLI. (See the Overview for a comparison of these development options.) This section also shows how to modify Cordova apps within Visual Studio. Regardless of which approach you take, you need to install the Visual Studio SDK, as described below.
Cordova Windows on Windows 8.1 and Windows Phone 8.1 rely on Internet Explorer 11 as their rendering engine, so as a practical matter you can use IE's powerful debugger to test any web content that doesn't invoke Cordova APIs. The Windows Phone Developer Blog provides helpful guidance on how to support IE along with comparable WebKit browsers.
Cordova apps targeting Windows can be developed on a Mac, either by running avirtual machine environment or by using Boot Camp to dual-boot aWindows partition. Consult these resources to set up the requiredWindows development environment on a Mac:
App compatibility is determined by the OS that the app targeted. Apps are forwardly-compatible but not backwardly-compatible, so an app targeting Windows 10 cannot run on 8.1, but an app built for 8.1 can run on 10.
You may decide that you want to build a particular version of your application targeting a particular OS (for example, you might have set that you want to target Windows 10, but you want to build for Windows Phone 8.1). To do this, you can use the --appx parameter:
Windows 10 supports a new "Remote" mode for Cordova apps (and HTML apps in general). This mode enablesapps to have much more freedom with respect to use of DOM manipulation and common web patterns such as the useof inline script, but does so by reducing the set of capabilities your app may use whensubmitted to the public Windows Store. For more information about Windows 10 and Remote Mode, look atthe Understanding Remote Mode vs Local Mode section.
Once you build a Cordova app, you can open it with Visual Studio. The various build commands generate a Visual StudioSolution (.sln) file. Open the file in the File Explorer to modify the project within Visual Studio:
The projects for different Windows versions are displayed separately in the solution explorer. You can choose the deploy target version by right clicking the 'solution' (topmost entry in the solution explorer) and then going into 'Properties'. Here you can update the 'Single start up' field. The controls below Visual Studio's main menu allow you to test or deploy the app:
NOTE: Consult the Overview for advice on how to use Cordova'scommand-line tools or the SDK in your workflow. The Cordova CLI relieson cross-platform source code that routinely overwrites theplatform-specific files used by the SDK. If you want to use the SDK tomodify the project, use the lower-level shell tools as an alternativeto the CLI.
Note: Resume and pause events are not triggered normally when debugging apps using Visual Studio. This is because Windows does not suspend your app when it is being debugged. The only way to change the application state is through the 'Lifecycle event' options inside Visual Studio. The events should work as expected when the app is run on a device/emulator without the debugger attached.
Signing is required for distributing and installing Windows Store apps. This process is normally handled by Visual Studio when you deploy a package for release. To do this without Visual Studio we need to create our own certificates. This article has instructions on how to do that.
Once you have the .pfx file created and provided to build.json file, you might get the following error: "The key file may be password protected. To correct this, try to import the certificate manually into the current user's personal certificate store.". In order to import it you have to use certutil from an admin prompt:
Once installed, next step is to add packageThumbprint and packageCertificateKeyFile to build.json. In order to find the packageThumbprint, search for the CommonName you've associated with the certificate:
Note that cordova-windows appends build flags from build.json and CLI arguments in specific order. In particular, flags from build.json are being appended before build flags from CLI, which basically means that CLI flags override ones from build.json in case of any conflicts.
d3342ee215