Errors I face at the final step of creating an installer for my Qt app - c++

EDITED:
Hi all,
I used the Qt Documentations for creating an installer for my Qt app using Qt Installer Framework.
I think I'm at the final step. Please have a look at the issue:
I have a package_directory folder on my Windows Desktop with these sub-folders. The config.xml file contains this. The data subfolder contains the data.7z file. I then created a licens.txt file on my Desktop. The meta subfolder contains a package.xml file with this content.
Then I created a folder named Result on my Desktop and pasted the Cal.exe file from the Release folder onto it.
And finally Ran the following command:
C:\Qt\QtIFW2.0.3\bin\binarycreator.exe -c C:\Users\CS\Desktop\package_directory\config\config.xml -p C:\Users\CS\Desktop\package_directory\packages C:\Users\CS\Desktop\Result\Cal.exe
The installer was created in the Result folder. But I got the following message from the command line:
Warning: The <Name> tag in the 'C:/Users/CS/Desktop/package_directory/packag
es/com.vendor.product/meta/package.xml' is ignored - the installer uses the path
element right before the 'meta' ('com.vendor.product').
C:\Qt\QtIFW2.0.3\bin>
Should I ignore it? If not how to solve it, too, please?
The installer file exists in the Result folder on Desktop. When I install it and select a folder on Start Menu (say Accessories or Start Up) to have the shortcut of the program, no shortcut will be created or saved there!! :(
What is the reason for that problem and how should I solve it please?

Related

Creation of the virtual directory failed with error: cannot write configuration file applicationhost.config

I'm just simply trying to open up a VS 2017 project. When I open the solution, I get the following error message:
Creation of the virtual directory http://localhost:58051/failed with the error: Filename: \?\C:\Users\Visual Studio 2017\Projects\Testing\Version 2.0.vs\config\applicationhost.config Error: Cannot write configuration file
I've checked the folders along the file path and they are not encrypted. All the folders along the file path have a black box for the Read Only attribute. When I go to the config folder and clear out the black box for the Read Only attribute and Apply the setting, I find if I exit and go back to the same folder, the black box reappears for the Read Only attribute. I've read that the black box doesn't really mean the Read Only attribute has been turned on. If the Read Only attribute was actually turned on, I should expect to see a check mark instead. However, this doesn't explain why I can't open the solution.
After I click the OK Button to the VS Error message, VS just says the solution is "(unavailable)" in the Solution Explorer.
Any help would be greatly appreciated.
I too had this problem with my project files located on OneDrive. The way I resolved it was I renamed the applicationhost.config file located in the ".vs\config" directory of your root project directory then reloaded the web project. This will create a new applicationhost.config file.
I had the same error message sharing a project between 2 machines via OneDrive and fixed it as follows:
1 - Closed VS.Net
2 - Opened [myappnamefolder].vs\config\applicationhost.config in Notepad
3 - Searched the open file for the filename in my error message (In your case C:\Users\Visual Studio 2017\Projects\Testing\Version 2.0.vs\config\applicationhost.config ).
It was found under system.applicationHost, sites, site name, application path, virtualDirectory - physicalPath
4 - Amended the physicalPath value to point to the valid path of the project's config file as above.
5 - Saved the applicationhost.config file
My paths were different because I had different home user directories on each machine. (User A & User B)
I have resolved this error with this way mention as below:
STEP 1:
Go to on that path
C:\Users\navz\OneDrive\Documents\IISExpress\config
STEP2:
When you reach on this folder "config"
in this folder we can see "applicationhost" file
STEP3:
Close the Visual studio existing project and delete the applicationhost file(see on Step 2 path)
Then open the existing project again, it will be reloaded automatically and work properly.
Had same problem then looked into vs\config\applicationhost.config and it was encrypted. I unencrypted file and solution loaded with no problems.
I've had this problem several times using VS 2017 with Onedrive. Resolved it by renaming the application.config and having VS recreate it. Just as well could have edited line in the file. See the Diff below as an example.
The config file is located in something like C:\Code\MyProject\.vs\config\.
I just encountered this error. I followed the steps in this answer: https://stackoverflow.com/a/50508207/1166163
When I tried to save my changes I realised TFS had marked the file as read-only, preventing VS from updating the value. Removing the read-only attribute fixed the problem.
None of the above worked for me. I ended up deleting and recloning the repo that was giving me problems. It then opened up just fine.
Windows 10 Defender was causing this for me. When I disabled control folder access it worked again. Odd, because it had been working with that setting on for a while.
my drives were different - but the main codebase was shared between the two machines - so on one it was in the d drive - so i mapped the parent subdirectory on the second machine to be the d drive ... which resulted in the same paths then on both ... i just had to open the solution from the d drive on the second machine

Where should i save codeblocks projects?

so i downloaded codeblocks codeblocks-13.12mingw-setup-TDM-GCC-481.exe
when i try to run main.cpp i get this error message:
Failed to open 'C:\Users\$imba\Documents\Codeblocks projects\test\main.cpp'.
this is a detailed summary of what i did prior to opening main.cpp
i selected the defaults all the way through the end. I created a seperate folder (called Codeblocks projects) in my documents to save the projects in.
now when i went to create a new folder, i selected console application, C++ and then i named my project test. i decided to create the project in the Codeblocks projects folder that i created. the resulting filename comes out to be C:\Users\$imba\Documents\Codeblocks projects\test\test.cbd
i then selected
GNU GCC Compiler,
'Create Debug Configuration: Debug'
output dir: bin\Debug\
object dir.: obj\Debug\
i selected create Release configuration,: 'Release'
output dir.: bin\release\
objects output dir.: obj\ Release
Finish
when i double click on main.cpp is when i get the error message
Failed to open 'C:\Users\$imba\Documents\Codeblocks projects\test\main.cpp'.
please help, i need this program for my course.
Try saving it in a folder in C:\, like C:\Cpp\. Code::Blocks may be having problems with the space or the $ in the file path.
I just created a new folder CB-Project under my D: drive where I have codeblocks installed.
You may want to look in the directory that you have CB installed in first, you may also find this in program file (x86) or the codeblocks sub directory. Look for a file named that may have proj or project in it's name. If you don't find it you can just create a new folder. You will have to put the new folder name in the CB path so it will find it.

Run a jar Rhapsody app file

I have created some Java applications to extend Rhapsody using Java API and I have deployed them successfully to the Rhapsody environment (Right click on the project -> Apps).
I can see the exported .jar files under the directory RhapsodyApps/apps.
My question is, How can I run them from the command line (Under windows 7)???
Thank you in advance
What I managed to do is to create a .bat file, using "Generate Apps Execution Batch File". As I mentioned in my last post it did not exist in the "Apps" menu of rhapsody. Besides, it existed in the "...\share\RhapsodyApps\apps" directory with the name "SynchronousScriptInvocation.jar". I hardcoded the RhapsodyApps.hep file, by adding the following:
#REM: This app generates a script which will invoke each app synchronously one after another. ...
name7=Apps\Generate Apps Execution Batch File
isPluginCommand7=1
command7=Apps
applicableTo7=Project,SysML,AUTOSAR_40,AUTOSAR_31,AUTOSAR_32,DDS,UPDM1_DoDAF20,UPDM2_DoDAF
isVisible7=1
I got the name (Generate Apps Execution Batch File) from the AppInfos.xml file.
Then, the plugin is displayed in the Apps menu in Rhapsody IDE, and I can generate the .bat file. Problems did not stop here. The batch file was not displaying my plugin and the reason was something with my JAVA_PATH configuration. Finally I modified the .bat file as following:
#rem This is auto generated script. Be careful on changing it manually.
#rem Build Order
set APP0=0df8829923eb43f4aab9d33ada1ddbf1
#set APPS= %APP0%
set JAVA_PATH=%JAVA_PATH%\bin\java
set JAVA_API=C:/work/User/Build.TRUNK/ProjectName/RhapsodyShare8/JavaAPI
set RhapsodyApps=C:/work/User/Build.TRUNK/ProjectName/RhapsodyShare8/RhapsodyApps
set CLASS_PATH="%RhapsodyApps%"/apps/RhapsodyAppLauncher.jar;"%RhapsodyApps%"/RhapsodyApps.jar;"%RhapsodyApps%"/apps.jar;"%JAVA_API%"/rhapsody.jar
"C:\Program Files (x86)\IBM\Rational\Rhapsody\8.0.5\jre\bin\java" -cp %CLASS_PATH% -Djava.library.path="%JAVA_API%" apps.RhapsodyLauncherApp %APPS%
Finally it works. I hope that this post will help somebody in the future.

WinJS Sample Code js file missing?

"WinJS ToDo Sample for Multi-Device Hybrid Apps" Sample Code Project (http://code.msdn.microsoft.com/WinJS-TODO-Sample-for-17295485/sourcecode?fileId=114491&pathId=1137423199), I tried download and run it , but the index.html file include
three file for winjs reference : ./css/ui-light.css , ./scripts/frameworks/base.min.js , ./scripts/frameworks/ui.min.js , can't be found in the project .
what's i missing some thing ?
The sample projects have been authored in a way that the requisite dependency frameworks will be automatically downloaded when you run the project for the first time.
However, the libraries may fail to download in case the script does not have the right permissions to execute. To fix this:
Open the folder where you’ve downloaded the sample app
Identify the FetchRequirements.ps1 file and right click it
Choose “Properties”
Click the Unblock button if it shows up
Try to run the project again through Visual Studio

Trouble getting a Qt Reference Document program to work(Minehunt)... its just blank when run... no errors though?

http://docs.huihoo.com/qt/4.7/demos-declarative-minehunt.html
When I build and run... I just get a blank white rectangle... game is MineHunt.
The source code is in the URL. I created files and copied and pasted into Qt Creator 4.7.
Running in Linux.
No need to downvote. Deploying qml apps does not seem to be easy for beginners. jdl, I don't know if I can help you. Currently I am only on Linux. But what I did:
I copied the whole folder minehunt in my destination folder (/tmp/mine). When I ran qmake I got:
WARNING: Include file
/tmp/mine/helper/qmlapplicationviewer/qmlapplicationviewer.pri not
found
So I also copied the examples/declarative/helper folder into /tmp/mine.
Looked like this:
/tmp
/mine
/minehunt
/helper
Then I changed into minhunt, did 'qmake' and 'make'. A few seconds later I had a working minehunt binary in /tmp/mine/minehunt/.
I'll try tomorrow the Windows build.
Edit: Ok, tried now under Windows 7. Qt4.
QtCreator opened.
Project ...qt\demos\declarative\minehunt\minehunt.pro
loaded. Normally in release mode compiled. No problem. A file minehunt.exe was created in ....qt\demos\declarative\minehunt\release. Started: White screen. Exactly as you described it. In ...qt\demos\declarative\minehunt I found a folder 'qml'. I moved this folder and the minehunt.exe into another folder (myMineFolder). Simulating a simple deployment this way. Clicked on minehunt.exe -> worked like a charm.
So my folder layout:
myMineFolder
qml
minehunt.exe
But of course, I have set my PATH variable correctly to my Qt installation.