Click here to Skip to main content
15,915,774 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I am trying to create a help file for the Windows Ce 5.0.
And I was able to display text also. But the problem is when I try to display the Image in the html file ,no image is getting displayed in the emulator.

MIDL
String path = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().GetName().CodeBase);
            Help.ShowHelp(this, path + @"\HTMLPage1.htm");



And the image is in the same folder as that of the exe as well as the html file.

<img src="tim.2bp" alt="Image Display"/>

And When I open the html page in the Windows Ce Emulator I am able to see the Image. But when the exe is calling the html page the image is not getting displayed.

I refered the msdn link for this..http://msdn.microsoft.com/en-us/library/ms229662.aspx[^]

Please help me to solve the issue...
Posted

1 solution

I modified your code thusly, the Path.Combine saves issues with having to add "\\" to everything.

C#
String path = Path.GetDirectoryName(Assembly.GetExecutingAssembly().GetName().CodeBase);
string file = Path.Combine(path, @"HTMLPage1.htm");
if(File.Exists(file))
{
    Help.ShowHelp(this, file);
}


Besides that, the example I saw requires that you install the file into the help directory. I got it to stop complaining by adding the image to the project and setting the "copy always" flag on the file.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900