我想在winform datagridview一个列中加入超链接,
点击链接实现向ie里下载pdf文件一样的效果,
急啊,明天task必须完成!!!!!!!!!!!好像挺不容易的,
谁能帮我啊???最好有demo code啊,不然不容易懂啊
谢谢啦!!!!
点击链接实现向ie里下载pdf文件一样的效果,
急啊,明天task必须完成!!!!!!!!!!!好像挺不容易的,
谁能帮我啊???最好有demo code啊,不然不容易懂啊
谢谢啦!!!!
解决方案 »
- winform 怎么不弹出保存对话框保存文件
- 字符串"你好1;"或者"你好1;你好2;你好3;"怎么拆分成数组?
- 高手给个数据中转服务器的方案!
- 怎样在程序中保存按钮的状态?
- 请问高人组件与构件、类的区别?Web Services是不是组件?
- 在C# 中,怎样在A类的其他方法中改变在一个A类的构造方法中传入的参数的值。例如
- 求助
- 在WINFORM程序,通过EXCEL.APPLICATION方式,修改了EXCEL表,为何程序里总是跳出确认框,能不能不跳出确认框,默认都是执行确认的。。
- 请问winform动态生成的控件如何保存位置等信息?
- 在C#中图片的存储用什么表示呀?谢谢了?
- VS2005 winform里如何自定义控件啊?
- 怎么在两个窗体之间来回传数据?
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=977920&SiteID=1
Dim hl As New DataGridViewLinkColumn
With hl
.Width = 150
.HeaderText = "Link"
End With
DataGridView1.Columns.Add(hl)
DataGridView1.Rows.Add(New Object() {"http://www.microsoft.com"})
End Sub
Private Sub DataGridView1_CellClick(ByVal sender As Object, ByVal e As System.Windows.Forms.DataGridViewCellEventArgs) Handles DataGridView1.CellClick
If e.ColumnIndex = 0 Then
Process.Start(DataGridView1.Item(e.ColumnIndex, e.RowIndex).Value.ToString)
End If
End Sub
{
DataGridViewLinkColumn link = new DataGridViewLinkColumn();
link.HeaderText = "link";
link.Name = "link";
this.dataGridView1.Columns.Add(link );
this.dataGridView1.Rows.Add(new object[]{"http://www.baidu.com"});
this.dataGridView1.CellClick += new DataGridViewCellEventHandler(dataGridView1_CellClick);
} void dataGridView1_CellClick(object sender, DataGridViewCellEventArgs e)
{
System.Diagnostics.Process.Start(this.dataGridView1[e.ColumnIndex, e.RowIndex].Value.ToString());
//throw new Exception("The method or operation is not implemented.");
}
{
linkbutton.atrribute.add(.....)
}