When creating a Windows form in C#, we would like to create a hyperlink so that when the user click on the link it would open up a web browser and display the desire website.

In order to do so you will need to use the control LabelLink.

1. First drag the LinkLabel from the Toolbar onto the form.

2. Then double click on the LinkLabel control to open the LinkClicked event.

3. Inside the event place this code:

System.Diagnostics.Process.Start("www.itjungles.com");'

Example:

private void lnkITJungles_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)

{

System.Diagnostics.Process.Start("www.itjungles.com");

}

C# Adding Hyperlink to Windows Form z的更多相关文章

  1. 如何用Web技术开发Windows Form应用

    现在H5很热,很多互联网公司的产品都采用混合编程,其中各个平台客户端的“壳”为原生控件,但是内容很多都是Web网页,因此可以做出很多炫酷的效果.随着Node.js和Ionic等框架的出现,现在感觉Ja ...

  2. Windows Form 中快捷键设置

    在Windows Form程序中使用带下划线的快捷键只需要进行设置: 就能够工作.

  3. VS2008 Windows Form项目安装包生成详解

    2008 Windows Form项目的发布对有经验的程序员来说,可能不值一提,但对很多新手来说却不知道如何操作,因为在很多关于Visual Studio的书籍中也没有相关介绍,权威如<C# 2 ...

  4. VISUAL STUDIO 2008 WINDOWS FORM项目发布生成安装包详解(转)

    转自:http://www.cnblogs.com/killerofyang/archive/2012/05/31/2529193.html Visual Studio 2008 Windows Fo ...

  5. windows form (窗体) 之间传值小结

    windows form (窗体) 之间传值小结   windows form (窗体) 之间传值小结 在windows form之间传值,我总结了有四个方法:全局变量.属性.窗体构造函数和deleg ...

  6. Ninject之旅之十二:Ninject在Windows Form程序上的应用(附程序下载)

    摘要: 下面的几篇文章介绍如何使用Ninject创建不同类型的应用系统.包括: Windows Form应用系统 ASP.NET MVC应用系统 ASP.NET Web Form应用系统 尽管对于不同 ...

  7. Windows Form线程同步

    .Net多线程开发中,经常需要启动工作线程Worker thread处理某些事情,而工作线程中又需要更新主线程UI thread的界面状态.我们只能在主线程中操作界面控件,否则.Net会抛出异常. 那 ...

  8. C#通讯录——Windows Form Contact List

    C#通讯录 Windows Form Contact List 主窗口 using System; using System.Collections.Generic; using System.Com ...

  9. 在WPF中添加Windows Form控件(包括 ocx控件)

      首先,需要向项目中的reference添加两个dll,一个是.NET库中的System.Windows.Forms,另外一个是WindowsFormsIntegration,它的位置一般是在C:\ ...

随机推荐

  1. Struts2从版本2.2.1升级至2.3.15.1出现的问题

    问题一 原版本Struts2.2.1中的JSP代码如下: <a class="buttonSelect" href="/manage/machine/uploadF ...

  2. 六步实现Rest风格的API

    Rest的作者认为计算机发展到现在,最大的成就不是企业应用,而是web,是漫漫无边的互联网web世界.Web能有这么大的成就,它值得我们研究.所以Rest的作者仔细研究了Web,按照Web的世界一些关 ...

  3. 黑马程序员-- .net基础加强8之委托,事件,程序集

    ---------------------- ASP.Net+Android+IOS开发..Net培训.期待与您交流! ---------------------- 一.委托 ============ ...

  4. lintcode :Integer to Roman 整数转罗马数字

    题目 整数转罗马数字 给定一个整数,将其转换成罗马数字. 返回的结果要求在1-3999的范围内. 样例 4 -> IV 12 -> XII 21 -> XXI 99 -> XC ...

  5. 对于linux下system()函数的深度理解(整理)

    原谅: http://blog.sina.com.cn/s/blog_8043547601017qk0.html 这几天调程序(嵌入式linux),发现程序有时就莫名其妙的死掉,每次都定位在程序中不同 ...

  6. GC垃圾回收之GC.KeepAlive方法

    http://msdn.microsoft.com/zh-cn/library/system.gc.keepalive.aspx http://www.cnblogs.com/ren700622/ar ...

  7. 获取其它进程窗口中的状态栏信息(FindWindowEx GetWindowThreadProcessId OpenProcess SendMessage轮番轰炸)

    HWND hWnd = ::FindWindow(NULL, _T("XXXXX")); if(NULL == hWnd) { return ; } HWND hWndStatus ...

  8. TCP-心跳

    心跳包就是在客户端和服务器间定时通知对方自己状态的一个自己定义的命令字,按照一定的时间间隔发送,类似于心跳,所以叫做心跳包.   用来判断对方(设备,进程或其它网元)是否正常运行,采用定时发送简单的通 ...

  9. Xml文件保存值不能及时更新

    今天在Xml文件中修改了一个值,调试时,发现读取的不是最新值.经过各种调试,还是不能解决.只好把文件项目给编译了一遍,在调试时,把在及时窗口,把变量值给改了一下啊,就是可以读到最新配置了.停止程序,在 ...

  10. C#ShowCursor光标的显示与隐藏

      使用using System.Runtime.InteropServices; [DllImport("user32.dll" , EntryPoint = "Sho ...