title: Setup Project Deployment of a Windows Forms App : Image Path Error (itextsharp)
body: <p>My Windows Form is running perfectly in Build and Release Mode. I created one pdf file on Button Click. But when I created setup file then the pdf file is generated with errors. If i remove the image from my project then everything is going smooth. I placed my image in release folder and path for the image is : </p>
  
  <pre><code>string exeFile = (new 
  Uri(Assembly.GetEntryAssembly().CodeBase)).AbsolutePath;
  string exeDir = Path.GetDirectoryName(exeFile);
  string fullPath = Path.Combine(exeDir, "header.jpg");
  iTextSharp.text.Image jpg = iTextSharp.text.Image.GetInstance(fullPath);
  document.Add(jpg);
  </code></pre>
  
  <p>i used itextsharp library for creating the pdf</p>
  
  <p>Github Link : <a href="https://github.com/loveleenkaurnancy/WindowsFormsApp1" rel="nofollow noreferrer">https://github.com/loveleenkaurnancy/WindowsFormsApp1</a></p>
  
  <p>Snapshot</p>
  
  <p><img src="https://i.stack.imgur.com/xaPJ3.png" alt="Click here : Snapshot"></p>