I have following excel data out of which i wanna make first column and header row read-only.
CityMaster POC HeadCount
Mumbai Prasad S 2
Delhi Kishan T 5
Banglore Shilpa S 7
Chennai Prasad S 2
Second and third data should be editable.
I tried this and it worked:
workSheet.Protection.IsProtected = true;
workSheet.Cells[2, 3, pocDeatils.CityMaster.Rows.Count + 1, 4].Style.Locked = false;
for more detail refer below link: https://epplus.codeplex.com/SourceControl/latest#SampleApp/Sample6.cs
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.