![]() |
Make one column Invisible.
Hi,
Could someone let me know if it is possible to make a Column in Excel sheet Invisible by VBA Programming. I need to Hide a Column which contains Data which is useful for my Programming but not required to be viewed by the User. If i hide the column by, for e.g: Range("N1").Value = "SKU Number" Columns("N:N").Hidden = True and then insert the required data into this, the user may by mistake unhide it or possibly overwrite it somehow. I dont what this to happen. Its like i want to make the column invisible and somehow lock it so that the user will not be able to unhide it. how do i go about with this??? Thanks in Advance for any help. Regards, Neeraja. |
Make one column Invisible.
You could put it outside the normal viewing area and set the scrollarea
"Neeraja" wrote in message ... Hi, Could someone let me know if it is possible to make a Column in Excel sheet Invisible by VBA Programming. I need to Hide a Column which contains Data which is useful for my Programming but not required to be viewed by the User. If i hide the column by, for e.g: Range("N1").Value = "SKU Number" Columns("N:N").Hidden = True and then insert the required data into this, the user may by mistake unhide it or possibly overwrite it somehow. I dont what this to happen. Its like i want to make the column invisible and somehow lock it so that the user will not be able to unhide it. how do i go about with this??? Thanks in Advance for any help. Regards, Neeraja. |
Make one column Invisible.
..... and how do you set the scroll area ?
Thanks, J. ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
Make one column Invisible.
For example:
Worksheets("Sheet1").ScrollArea = "A1:D15" Troy "jagstirling" wrote in message ... .... and how do you set the scroll area ? Thanks, J. ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
Make one column Invisible.
Use sheet protection. In other words, after hiding the column, use this
line: ActiveSheet.Protect Password:="cat" To unprotect, use: ActiveSheet.Unprotect Password:="cat" To prevent anyone from seeing the password by simply looking at the VBA code, right-click the VBAProject(yourfilename) in Project Explorer, select VBAProject Properties, click on the Protection tab, select "Lock project for viewing," and give it a password. Then save, close the file, reopen and the VBA code will be protected from viewing without the password. Obviously change the password to suit your needs.... MRO "Neeraja" wrote in message ... Hi, Could someone let me know if it is possible to make a Column in Excel sheet Invisible by VBA Programming. I need to Hide a Column which contains Data which is useful for my Programming but not required to be viewed by the User. If i hide the column by, for e.g: Range("N1").Value = "SKU Number" Columns("N:N").Hidden = True and then insert the required data into this, the user may by mistake unhide it or possibly overwrite it somehow. I dont what this to happen. Its like i want to make the column invisible and somehow lock it so that the user will not be able to unhide it. how do i go about with this??? Thanks in Advance for any help. Regards, Neeraja. |
Make one column Invisible.
Hi,
I dont need to protect the Entire Sheet. The User actually needs to change the values in a Column. Suppose there are 2 columns "SKU Number" and "Quantity". The user should be updating the "Quantity" column and should not be touching the "SKU Number" Column. After updating the "Quantity" column the user runs a Macro which will make use of the values in the "SKU Number" Column. Actually i am hiding this column. but i also want to take care that the user by mistake wont unhide it and change these values. In a way I dont need to protect my entire Active Sheet with a Password, i just need to take care of one Column. Any help on this would be very grateful. Thanks, Neeraja. -----Original Message----- Use sheet protection. In other words, after hiding the column, use this line: ActiveSheet.Protect Password:="cat" To unprotect, use: ActiveSheet.Unprotect Password:="cat" To prevent anyone from seeing the password by simply looking at the VBA code, right-click the VBAProject(yourfilename) in Project Explorer, select VBAProject Properties, click on the Protection tab, select "Lock project for viewing," and give it a password. Then save, close the file, reopen and the VBA code will be protected from viewing without the password. Obviously change the password to suit your needs.... MRO "Neeraja" wrote in message ... Hi, Could someone let me know if it is possible to make a Column in Excel sheet Invisible by VBA Programming. I need to Hide a Column which contains Data which is useful for my Programming but not required to be viewed by the User. If i hide the column by, for e.g: Range("N1").Value = "SKU Number" Columns("N:N").Hidden = True and then insert the required data into this, the user may by mistake unhide it or possibly overwrite it somehow. I dont what this to happen. Its like i want to make the column invisible and somehow lock it so that the user will not be able to unhide it. how do i go about with this??? Thanks in Advance for any help. Regards, Neeraja. . |
All times are GMT +1. The time now is 02:58 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com