Windows Mobile Compact Framework Build Error: CAB file … could not be created
Asked Answered
M

4

6

I get the following error when trying to build a .CAB in visual studio on my new PC. The source is identical. The Registry warnings are not present on the old PC either.

Windows CE CAB Wizard

Warning: Section [RegKeys] has no data
Warning: Section [DefaultInstall] key "AddReg" - there are no section entries to process
Error: CAB file "D:\Dev\...\MyProject.CAB" could not be created

ERROR: The Windows CE CAB Wizard encountered an error.  See the output window for more information.

No other errors show in the build log for the cabwiz.exe build step.

Any suggestions?

Mansell answered 27/1, 2014 at 15:0 Comment(0)
M
11

Move the source code to C: drive and build it there, instead of D: drive.

It appears that when cabwiz.exe (Visual Studio) is installed on C: drive, it does not like building projects on D: drive.

Similar issues with network drives noted at http://windowsmobilepro.blogspot.co.uk/2005/11/error-cab-file-could-not-be-created-no.html

Mansell answered 27/1, 2014 at 15:0 Comment(2)
Moved my project to C Drive, but problem still existsSkylight
working for me thankx... problem started after i upgrade my OS to 8.1 and install VS2008Sainted
D
6

Finally I found an answer. All my problems comes from the 8.3 file name generation.

You have to check two thing.

Registry key NtfsDisable8dot3NameCreation under HKLM/SYSTEM/CurrentControlSet/Control/FileSystem

Valid values are:

  • 0 - Disable 8.3 name generation
  • 1 - Enable 8.3 name generation
  • 2 - Name generation will be evaulated by volume settings

Matty Brown suggested the following (not tested, but may help):

Valid values are (Windows 10 1809):

  • 0 - Enable 8dot3 name creation on all volumes on the system
  • 1 - Disable 8dot3 name creation on all volumes on the system
  • 2 - Set 8dot3 name creation on a per volume basis
  • 3 - Disable 8dot3 name creation on all volumes except the system volume

Volume based settings.

You need an admin command prompt. Check 8.3 name generation with

fsutil 8dot3name query d:

where "d:" is your volume

If the result inform you that your volume has disabled 8.3 name generation, you can set it easily with

fsutil 8dot3name set d:

Two more step is needed. You need a restart, and you have to move files from there and move it back to the original place.

The 8.3 name generation linked to the file operations.

Thats all.

I'm happy now with my new W10 ultrabook with VS2008 and a big WinCe 6 solution.

Disprize answered 19/5, 2016 at 13:36 Comment(3)
You've got the values the wrong way round - I've updated your answer with the possible values for Windows 10 1809.Fumed
@MattyBrown I modified my answer.Maidenhood
Works for me on Windows 10 Family edition (build 19043.1348)Kissinger
R
5

I know it's a bit too late, but I'll leave this tip for future visits:

Check for whitespaces in Solution & CAB project paths, and also in file names.

Rubious answered 19/3, 2015 at 12:45 Comment(0)
P
1

I ran into this error while trying to build a legacy CAB project on our new TFS Build Server running Windows 2012. Ironically, the script to build the mobile app and CAB project worked fine on my local development machine, but go the vague "Windows CE CAB Wizard Error: CAB file XXXXXX could not be created" error when I ran it on the build server, via both a TFS build definition or manually.

The article previously mentioned at http://windowsmobilepro.blogspot.co.uk/2005/11/error-cab-file-could-not-be-created-no.html was very thorough and helpful. I used the SUBST trick to shorten the project path and eliminate the spaces in the path names, and the script could then run on TFS / Win2012.

Pasteurization answered 9/11, 2015 at 14:51 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.