.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Forum >> C# >> Post New QuestionBookmark and Share Subscribe to Forum

How to open one .chm help file in c# windows application menu bar....

Posted By: susant     Posted Date: December 18, 2008    Points:2   Category :C#
Hi all

I have one .chm file and one menu like HELP..
when user will click on help it will open the .chm file...
and also when he will click 'f1' he can also see my .chm file..

How to do that..

susant

Responses
Author: Amit Mehra             
Posted Date: December 18, 2008     Points: 5   

Hi,
You can use below code to open .chm file in windows application.


System.Diagnostic.Process.Start("c:\a.chm");


Thanks,
Amit
Please "Mark As Answer " if this post help you.
Author: Pankaj Mishra             
Posted Date: December 18, 2008     Points: 5   

Hi Susant,

For Using F1 Button from your windows application, Just Drag "HelpProvider" (F1 Help Provider) component from Visual Studio ToolBox to your application . Then Set its "HelpNameSpace" to your .chm file. and you are done.

You can also refer this article

http://www.dotnetspark.com/kb/162-open-help-file-on-f1-function-key-press.aspx

Hope this will help you.

Cheers
Pankaj

Author: susant             
Posted Date: December 18, 2008     Points: 5   

Hello All

to open help file this code is working fine..
--------------------------------------------------
string fbPath = Application.StartupPath;
string fname = "help.chm";
string filename = fbPath + @"\" + fname;
FileInfo fi = new FileInfo(filename);
if (fi.Exists)
{
Help.ShowHelp(this, filename, HelpNavigator.Find, "");
}
else
{
MessageBox.Show("Help file Is in Progress.. ",MessageBoxButtons.OK, MessageBoxIcon.Information);

}


But requirement like:
suppose i am in purchase form and pressing F1 then it will show the purchase help from help.chm file

suppose i am in sales form and pressing F1 then it will show the sales help from help.chm file..

can we do that....



Post Reply

You must Sign In To post reply
 
 
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more Here
Quick Links For Forum Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  OOPs  SilverlightIISJQuery
JavaScript/VBScriptBiztalkWPFPatten/PracticesWCFOthers
www.DotNetSpark.comUnAnsweredAll

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend