This module.xml file is located in the folder named "Images". All images are also in this folder (using the sharepoint development tools for Visual Studio 2008 v1.3). The wsp package should know all the files to be added, so you need to add each file. (rename .wsp to .cab and open it. Then you can see all the files in the solution)
<Elements Id="8f8113ef-75fa-41ef-a0a2-125d74fc29b7" xmlns="http://schemas.microsoft.com/sharepoint/">
<Module Name="Images" Url="Style Library/Images/myfolder" RootWebOnly="TRUE">
<File Path="hvi_logo.bmp" Url="hvi_logo.bmp" Type="GhostableInLibrary" />
<File Path="hvi_logo_small.bmp" Url="hvi_logo_small.bmp" Type="GhostableInLibrary" />
<File Path="epj-logo.png" Url="epj-logo.png" Type="GhostableInLibrary" />
</Module>
</Elements>
You could create a small C # application to create an xml file for you, something like this:
var info = new DirectoryInfo(@"c:\pathToImageFolder");
var files = info.GetFiles();
TextWriter writer = new StreamWriter(@"c:\pathToImageFolder\module.xml");
writer.WriteLine("<Elements Id=...");
foreach (FileInfo file in files)
{
writer.WriteLine(string.Format("<File Path='{0}' Url='{0}' Type='GhostableInLibrary' />",file.Name));
}
writer.WriteLine("</Elements>");
writer.Flush();
writer.Close();
Tomso source
share