Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / IDE / March 2005

Tip: Looking for answers? Try searching our database.

VS.NET "Cab" deployment project loosing folder information

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Stephen Walch - 23 Mar 2005 01:18 GMT
Trying to use VS.NET to create a CAB file.  My C# project contains a lot of
"Content" resources in folders and subfolders, but when I add the Project
Output/Content to my CAB file, all the folder information is lost.  All I
get is a flat CAB file with all the resource files in the "top level"
folder.  Is this just a VS.NET limitation?  If so, I can't believe that too
many people use this feature.  Or maybe I am missing something?

Thanks!
Gary Chang[MSFT] - 23 Mar 2005 09:30 GMT
Hi Stephen,

>...  All I get is a flat CAB file with all the resource files in the "top
level"
>folder.  Is this just a VS.NET limitation?  If so, I can't believe that too
>many people use this feature.  Or maybe I am missing something?

yes, this behavior is as expected, you don't miss anything. The VS.NET's
CAB file project only provides the basic function to cab your project's
content files, it is unable to preserve their original directory hierarchy.

If you want to cab your project's content files with their directory
hierarchy, you have to use the cabarc.exe to make a cab file manually: you
can open the Visual Studio .NET 2003 Command Prompt console window, then go
to your application's project directory, use the following command sample
to cab your content files:

1) All and only the content files exist in the contents directory and its
sub-directories:
cabarc -p -r N cnts.cab contents\*.*

2) All and only the content files exist in the content1 directory(and its
sub-directories) and content2 directory(and its sub-directories) :
cabarc -p -r N cnts.cab content1\*.*  content2\*.*

2) Both the xml files and txt files in the content1 directory(and its
sub-directories) and only the txt files in the content2 directory(and its
sub-directories) :
cabarc -p -r N cnts.cab content1\*.xml  content1\*.txt content2\*.txt

Also you can type the "cabarc" to review its usage info.

Thanks!

Best regards,

Gary Chang
Microsoft Community Support
--------------------
Get Secure! ??C www.microsoft.com/security
Register to Access MSDN Managed Newsgroups!
http://support.microsoft.com/default.aspx?scid=/servicedesks/msdn/nospam.asp
&SD=msdn

This posting is provided "AS IS" with no warranties, and confers no rights.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.