Solved

Change %Installdir% for Windows mobile CAB file StorageCard

Posted on 2010-08-19
8
1,848 Views
Last Modified: 2013-12-27
Hy,

I am using VS 2008 to develop Windows mobile C# and C++ applications. I am using the CAB-project to build my CAB files. Now a have the following problem: My user should have the possibility to choose the Installation directory device or storage card. I want to use the application folder but done want the default value because I want the directory structure \AppFolder\Company\App and not the autogenerated value \AppFolder\App.

I looked for the reason of this  behavior an found the section:
[CEStrings]
AppName="ApplicationStandard 2.1.2.6"
InstallDir=%CE1%\%AppName%
in the the autogenerated inf-File.

Does anyone know a possibility to change the value of to InstallDir=%CE1%\Comanny\APP every time when I rebuld the CAB automatically. I only found the solution to build the CAB, change the CEstring manually an rerun the bulid of the CAB manually.

Does anyone know a better solution?

0
Comment
Question by:MobileStone
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
8 Comments
 
LVL 48

Expert Comment

by:Mikal613
ID: 33474426
In visual studio where you have your file explorer on the cab manager you can add a Folder to tree structure.
FileCab.JPG
0
 
LVL 1

Author Comment

by:MobileStone
ID: 33474567
Thank for the quick reply,

but I am sorry it is no solution because if you look at the directory tree on the Mobile Device you will see there is a directory above Mycompany with the name Application name.
0
 
LVL 48

Expert Comment

by:Mikal613
ID: 33474616
add a special folder
FileCab.JPG
0
Enroll in June's Course of the Month

June's Course of the Month is now available! Every 10 seconds, a consumer gets hit with ransomware. Refresh your knowledge of ransomware best practices by enrolling in this month's complimentary course for Premium Members, Team Accounts, and Qualified Experts.

 
LVL 1

Author Comment

by:MobileStone
ID: 33474698
if have tried this before, but if I do it this way, there is no possibilty for user to elect the install destination (device or storagecard) an even if I tried it to do with a setup.dll I have found no way to change the %installdir% with C++ code

0
 
LVL 1

Accepted Solution

by:
MobileStone earned 0 total points
ID: 33482490
Now I have solved my problem for an automatic CAB build with automatic changed %InstallDir%.

Normaly the last thing in a VS 2008 solution for mobile devices is building the CAB file. I added one more C++ project to the mobile solution, named ChangeCAB, wich does nothing. In the build order of the VS 2008 solution I build this project after the CAB file. Within this project I only use the prebulid and postbuild events. In the prebuild event I change then line with InstallDir="%CE1%\%AppName" and replace the line with InstallDir="%CE1%" with an editor macro. In the postbuildevent I rerun cabwiz.exe For a better maintainabilty I use $(SolutionDir) rather then the absolute path in the command line for cabwiz.exe

Now everything is fine and I can rebuild my VS 2008 mobile project.

Thanks for trying to help me.
0
 
LVL 48

Expert Comment

by:Mikal613
ID: 33483949
im glad :)
0
 
LVL 1

Author Comment

by:MobileStone
ID: 34711962
Everything is no ok
0
 
LVL 1

Author Closing Comment

by:MobileStone
ID: 34759141
No other answer could solve the problem
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preface: This article is part of a series focused on cross platform mobile app development (specifically Android and iOS) using the Alloy framework and Titanium Studio made by Appcelerator (https://www.appcelerator.com/). This article presumes a wor…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question