Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesMulti-package manifest and resources.zipMulti-package manifest and resources.zip
Previous
 
Next
New Post
7/9/2012 4:16 PM
 

I'm creating multiple modules for use in DNN 6.1.5.  The modules reside in a single project.  I used the Christoc templates to develop the modules, and msbuild tasks (required by the templates) to package them.  My .DNN file contains two <package> entries within <packages> - one for each module.  Everything works great except for one thing - the resources.zip file is not being generated correctly.

Within each package, I have the following entry for the resource file:

<component type="ResourceFile">
     <resourceFiles>
         <basePath>DesktopModules/CompanyFolder</basePath>
         <resourceFile>
            <name>Resources.zip</name>
         </resourceFile>
     </resourceFiles>
</component>

After the msbuild task completes, I have a resources.zip file that contains files for ALL modules, not the specific module I was targeting.  This makes sense, since I was referencing the same file name in each module.  (Duh moment...) 

So I thought I should give each resource file a unique file name in the .dnn file (based on the module).  In other words, for the payroll component, I would call it PayrollResources.zip.  For the phone directory component, I would call it PhoneDirectoryResources.zip.  I'm hoping this will work.  However, I don't know how to automate the generation of these files.  The msbuild task appears to be hard-coded to use a file name of resources.zip.  It doesn't care what file name is specified in the .dnn file. 

So my questions are...  1) Am I on the right track in regards to zipping the resources and 2) is there an easy way to automate the generation of unique resource.zip file names as part of the build / packaging process?  (I assume the msbuild script would need to be tweaked, but this is not an area that I'm very familiar with.  Any assistance in this area would be greatly appreciated.)

 
New Post
7/9/2012 4:41 PM
 

1) yes you are on the right path with creating multiple resource.zip files

2) you would have to modify the MSBuild script to create two unique ZIP files. I would recommend you look at the InstallInclude section

<ItemGroup>
     <InstallInclude Include="**\*.ascx" />
     <InstallInclude Include="**\*.asmx" />
     <InstallInclude Include="**\*.css" />
     <InstallInclude Include="**\*.html" />
     <InstallInclude Include="**\*.htm" />
     <InstallInclude Include="**\*.resx" />
     <InstallInclude Include="**\*.aspx" />
     <InstallInclude Include="**\*.js" />
     <InstallInclude Include="**\*.dnn" />
     <InstallInclude Include="**\*.txt"  Exclude="**\obj\**;**\_ReSharper*\**;" />
     <InstallInclude Include="**\images\*.*" />
   </ItemGroup>


You will want to create two unique sections here that designate which files go into which ZIP. Then go to the section below where InstallInclude gets called to create the resources.zip file and duplicate that section as well. One call for each unique ZIP that you want to create.


Hopefully that at least gets you pointed in the right direction.


Chris Hammond
Former DNN Corp Employee, MVP, Core Team Member, Trustee
Christoc.com Software Solutions DotNetNuke Module Development, Upgrades and consulting.
dnnCHAT.com a chat room for DotNetNuke discussions
 
New Post
7/9/2012 4:57 PM
 
Thanks for your reply, Chris.

The two modules were in their own projects originally, and there were no issues when they were self-contained. I combined them because I was asked to create a third module, and I saw an opportunity to create / share some user controls between the modules. Unfortunately, I didn't realize I would be introducing this other problem with the resource file.

At any rate, I'll give your suggestion a shot and see where it takes me. Thanks again!
 
New Post
8/6/2012 7:36 AM
 

hello Chris


i am also facing the same problem

i have also added the code which is given by you to the .target file but nothing happened

i am using two file of ms build in my code which is

1) ModulePackage.targets

2) MSBuild.Community.Tasks.Targets

one more think i have seen the if i do the blank to this both file and then build my module in release mode it creates the installer and source pkg into the package folder ,i am very confused from where it is  taking the reference. 

please help me on the same 

 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesMulti-package manifest and resources.zipMulti-package manifest and resources.zip


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out