How to add DataGridViewLinkColumn property to dynamically generated columns in DataGridView?


i using c# winform without database connections.

in datagridview columns dynamically generated.at point of columns need datagridviewlinkcolumn property. how can achive this programmatically?

please solve problem.

http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridviewlinkcolumn.aspx

 

  private void addlinkcolumn() {   datagridviewlinkcolumn links = new datagridviewlinkcolumn();    links.usecolumntextforlinkvalue = true;   links.headertext = columnname.reportsto.tostring();   links.datapropertyname = columnname.reportsto.tostring();   links.activelinkcolor = color.white;   links.linkbehavior = linkbehavior.systemdefault;   links.linkcolor = color.blue;   links.trackvisitedstate = true;   links.visitedlinkcolor = color.yellowgreen;    datagridview1.columns.add(links); }  

malayalam sms website http://aspspider.info/smsmallu


Visual Studio Languages  ,  .NET Framework  >  Visual C#



Comments

Popular posts from this blog

Azure DocumentDB Owner resource does not exist

BizTalk Server 2013 Azure VM Log Shipping and HA for hosts

How to Share webservice object to all user