06-10-2010, 01:18 AM
1-How I can change the Header of column A
2- How I can set Readonly property to the the column(1,1) in excel sheet
06-10-2010, 04:46 AM
1. "Header" as in first row column A? If yes, then you can use the Range.Value property.
2. Have a look at the Workbook.ChangeFileAccess method in your Excel VBA helpfile.
06-10-2010, 04:47 AM
For the read only part,
just select all the cells
and untik locked.
Now do the same for cell(1,1) just tick locked.
Then on the review tab of the ribbon just click protect sheet.
now you cant change the value of colom a1 but stil can chabge anything else, if you want to protect other cells just go to protection and tik locked
06-11-2010, 05:43 PM
By default all cells come with the Locked property set to True. It will not take effect, however, unless the sheet is protected. I'm assuming you're looking for the VBA code for this? (Location, location, location....) As Colin showed you, use the .Value property to change the value of a cell via VBA, i.e. ...
ThisWorkbook.Sheets("YOUR SHEET NAME").Range("A1").Value = "Value changed!"
To change the protection of a worksheet, just use the .Protect method...
ThisWorkbook.Sheets("YOUR SHEET NAME").Protect
With everything else, read up on the Help files for both of these method/propertie's so you can make use of the proper syntax if desired.
If you're not looking for this information, you should be less ambiguous in your question.