Distribute iText.sharp PDF Merger Files - vb.net

I need to send my app to others and am using the iText.sharp library to merge PDF files.
What DLL's do I need to include in my distribution package?

I found the 2 DLL's that were needed out of the dozen or so from the package that made this work, itextsharp.dll and BouncyCastle.Crypto.dll.

Related

UWP APPX1101 errors with 2 unique data files

I'm in the process of converting a rather huge project to a Windows 10 Store app. I've gotten it to compile and now can't get past several APPX1101 errors - "Payload contains two or more files with the same destination path". The files are .xml files part of the project, e.g. "baseDir\Assets\foo\timers.xml" and "baseDir\Assets\bar\timers.xml". Different files and different paths.
The solution and projects are created by CMake (3.72). The cmake files have been modified to support creating a Windows 10 store app platform config.
It appears that the directory tree has been flattened and files are overlapping. But how or why eludes me. Every UWP project I've seen contains an "Assets" folder under the main project but this one does not. I see files such as Logo.png and SplashScreen.png in folder named "Resource Files". The files causing the errors are under the folder named "Assets" which existed before this was a UWP project.
Primarily:
How can I fix this error? Did I misconfigure CMake?
Additionally:
How to avoid directory flattening?
There are a few hundred data files taking up a few hundred megabytes used by the program. Will I need to add each of them to the solution to be packaged?
Updates:
I've gleaned more info but not enough to fully satisfy the question. The directory flattening in the output occurs due to how the files are added to the project via CMake and how the original Windows product was packaged. The XML files are added to the project with a full path in the .vcxproj. The .vcxproj.filters also use a full path to the file and a filter like "Data\foo". The desktop Windows version didn't need to care since it knew where to find it's data relative to the executable and was packaged by an external tool.
I've manually added an "Assets" filter and modified the .vcxproj and .vcxproj.filters files. The .vcxproj file needed a property added to the file's include. This uses relative paths and gets rid of the APPX1101 duplicate error.
.vcxproj
<XML Include="..\Base\Assets\foo\Data\timers.xml">
<Link>Assets\foo\Data\timers.xml</Link>
</XML>
.vcxproj.filters
<XML Include="..\Base\Assets\foo\Data\timers.xml">
<Filter>Assets\foo</Filter>
</XML>
Update 2
From what I can tell, it's not possible to get CMake to add a <Link> to XML and other .vcxproj Include types. I went through the latest CMake source code (3.8rc). The <XML Include> is added to the .vcxproj in cmVisualStudio10TargetGenerator::WriteExtraSource() in cmVisualStudio10TargetGenerator.cxx. Other types have the option to set the flag to add the <Link> but XML and other data types do not have code to set the flag.
The only options I can see are modifying CMake source or reworking the project to add data files using relative paths that match the same <Filter> for the matching Include in the vcxproj.filters file. This is only a problem with CMake. Visual Studio 2015/2017 have no problem adding assets above your tree. The MS UWP examples on GitHub do it to share common data between sample projects.
It's been a while and I'm posting this as an answer in case someone else runs into this problem. I'm not marking it accepted because I find the workaround rather weak. My knowledge of CMake is limited and my understanding of Universal Windows apps even less.
The primary issue is that by design, CMake does not build a relocatable solution. i.e. you can't xcopy a Windows solution to another tree and expect it to work as you would would with one generated from within the Visual Studio IDE.
The second issue is that this was a huge pre-existing project already targeting multiple platforms. And by huge, I mean it ships on a dual layer blu-ray disc. The location of asset files was fixed and was above the location of the CMake build folder. This caused files to be stripped of their path when added to the layout whenever their location was not under the expected assets folder.
There is no way in the current CMake (3.8) to add a <link> tag to the include in the project file. And CMake creates the include tag with the full path to the file not a relative one by design.
The workaround I came up with was to add a step to the batch file that invokes CMake to edit the .vcproj and vcproj.filters files to change the fixed asset paths relative ones and then added another step to create a symbolic link/junction (SysInternals.com) under the build folder to the location where the assets were. The assets now appear as being under the expected asset folder are now added correctly to the layout.
As I said, not ideal but it works. The real solution would be to re-organize all the data but this is not something that can happen for this project when a vast amount of data is generated from different script, tools, sources and contributors.

Remove the PDB file/functionality from Lib

I'm stuck in the following situation, I have been asked to rebuild a website, the original site was built and the solution had 5 projects, 4 of these where the different data layers and one of them was the actual website.
I only have the dll's of the 4 projects, so far I've managed to rebuild the website and adding the dll's to my project gives me access to the Entities and Repository layer etc... everything builds fine.
The problem is that when I run the project the debugger is trying to look for the Source files of the dll's that I've added which I don't have. Is there a way to remove the PDB file/functionality from the dll's that I've added? I don't need to or want to debug those dll's as I know that they are working correctly... and I dont have the code to change them if they arent.
Or to ask it in another way, is there a way to add them to my project and force them to not run with the Debugger?
Thanks
Ok, so to solve this problem I had to decompile the lib's of the four projects, create and place the code files in the exact directory that is specified in the PDB files and then compile and run the website.
I dont think it cared that the source files didn't compile again, it just needed to know that they where there.
After running the site i could delete the created path and source files and I haven't had a problem since.

Using MEF with exporting project that uses resources (xml) contained in the xap

I'm doing a proof of concept app in SL4 using MEF and as part of the app I am importing another xap from an existing Silverlight Project and displaying it in my host project.
The problem is that the existing app uses some .xml files (as content) and it uses linq2xml to load these files which are (assumed to be) bundled in the xap.
When I compose the application the initalization fails because the host app doesn't contain the xml files. If I copy these xml files into the host project and run it the composition works fine. However, I need to keep the xml files in the original project.
Is there a way that I can download a xap and look at it's contents for xml files and then load them into the host xap at runtime so that after the compostion takes place the xml resources that are required can be found?
Or should I work out some kind of contract with an import/export to pass the xml files to the host xap?
As the people developing the imported xaps (should the project go ahead) are from a different company, I would like to keep changes to the way they develop their apps to a minimum.
I assume you are using the DeploymentCatalog to download the second xap? Unfortunately there's no way to get at resources included in that xap. You could have the resources embedded in assemblies which are included in the xap, and then modify the way they are loaded.
If you really don't want to change the way the secondary xap is structured, you might be able to write your own DeploymentCatalog which would also allow you to load resources from the downloaded xap. The source code to DeploymentCatalog is available, so you could base it off of that.
I've managed to find a solution that I'm fairly happy with.
Instead of building the .xml files as 'content' to go within the xap, I have built them as 'resource' then used Application.ResourceStream() and loaded the xml using a stream.
It means the second xap developers will have to change the way they operate, but its only one extra line of code and changing the Build Action, I'm sure they can handle.

PackageMaker Troubles

My PackageMaker project was generating a .mpkg file, but then, all of the sudden, when I go to build, it only generates .pkg files. The .mpkg files are actually directories into which I place my custom installer bundle along with an InstallerSections.plist file to specify the order in which my custom view should display. The .pkg files are not directories and I have no way to add my custom installer bundle to it.
Anyhow, something is awry as PackageMaker no longer lets me generate a .mpkg file. Any idea why that might be? Is there some other way I should be approaching this?
Thanks.
p.s. If you are thinking of suggesting I ought to check out this tutorial, please don't bother. It's way out of date. Thanks.
Your pmdoc is a distribution project, and you've set the pmdoc's minimum system version to 10.5. PackageMaker always generates flat packages in this case.
There are three solutions:
Choose “Install Properties…” from the Project menu, and set the pmdoc's minimum system version to 10.4. This is the go-back-to-.mpkg solution.
Use the Flat Package Editor (hidden inside the PackageMaker bundle) to add the custom installer bundle. The contents of a .pkg file are the same as, and lain out similarly to, those of a .mpkg bundle.
Since flat packages are xar archives, use xar to extract the contents of the .pkg file to a temporary directory, add the custom installer bundle in that directory, then use xar to re-assemble the .pkg file from the temporary directory.

cannot see bin folder in fckeditor download

I tried to download fckeditor but there was no bin file containing any dll's after extracting the zip from: http://sourceforge.net/project/downloading.php?group_id=75348&filename=FCKeditor_2.6.4.zip
Am I being dense? Where is the bin file?
FCKEditor is just Javascript and CSS files, the .NET integration is in another package.
Note you need the one you downloaded too.
You're probably looking for the FCKeditor.Net WebControl. There is a separate download for this. See http://www.fckeditor.net/download.