I have a rather weird issue where the PDF Viewer can't load the file I specify in the code won't load at the program's startup. If I manually open the file, they open normally.
Source Code:
private static readonly string Ci = CultureInfo.InstalledUICulture.ToString();
private static readonly string ReadmeFile = Directory.GetParent(Assembly.GetExecutingAssembly().Location) + "\\ReadMe.pdf";
private static readonly string GreekReadme = Directory.GetParent(Assembly.GetExecutingAssembly().Location) + "\\el\\ReadMe_el.pdf";
private void ReaderWindow_Loaded(object sender, RoutedEventArgs e)
{
//ReaderViewport is the name of the PDFviewer on the XML file.
switch (Ci)
{
case "el-GR":
ReaderViewport.Load(GreekReadme);
break;
default:
ReaderViewport.Load(ReadmeFile);
break;
}
}