Generate Excel file with ReadOnly column using Response.Write in ASP.Net

Last Reply one year ago By dharmendr

Posted one year ago

Is it possible to generate excel with some cloumns readyonly using respone object?

I am using following code to generate excel. Its working fine but want set some column read only.

string style = @"<style> .textmode { mso-number-format:\@;border : 1px Solid Black;} </style>";
Response.Write(style);
Response.Output.Write(sw.ToString());
Response.Flush();
Response.End();

 

Posted one year ago

No it is not possible. You need to Excel Interope to do that. Refer below link for reference.

https://forums.asp.net/t/1830704.aspx?+how+to+make+excel+column+read+only+