Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell edit by user
I have a workbook that is used by more then one users, in the case 8 pepole. but i need it to were they can only edit there cells and no one else. -- wally0206 ------------------------------------------------------------------------ wally0206's Profile: http://www.excelforum.com/member.php...o&userid=14995 View this thread: http://www.excelforum.com/showthread...hreadid=546100 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell edit by user
maby somthing like this
Private Sub Workbook_Open() Dim u As String u = InputBox("User name please :") If u = "jones1" Then Sheets("Ark1").Range("A1:A10").Select: Selection.Locked = False If u = "jones2" Then Sheets("Ark1").Range("B1:B10").Select: Selection.Locked = False If u = "jones3" Then Sheets("Ark1").Range("C1:C10").Select: Selection.Locked = False If u = "jones4" Then Sheets("Ark1").Range("D1:D10").Select: Selection.Locked = False If u = "jones5" Then Sheets("Ark1").Range("E1:E10").Select: Selection.Locked = False If u = "jones6" Then Sheets("Ark1").Range("F1:F10").Select: Selection.Locked = False If u = "jones7" Then Sheets("Ark1").Range("G1:G10").Select: Selection.Locked = False If u = "jones8" Then Sheets("Ark1").Range("H1:H10").Select: Selection.Locked = False If u = "x" Then Sheets("Ark1").Range("A1:IV65000").Select: Selection.Locked = False Sheets("Ark1").Protect Password:="p", DrawingObjects:=True, Contents:=True, Scenarios:=True Range("A1").Select End Sub Private Sub Workbook_BeforeClose(Cancel As Boolean) Sheets("Ark1").Unprotect Password:="p" Range("A1:H10").Select Selection.Locked = True Range("A1").Select End Sub "wally0206" skrev: I have a workbook that is used by more then one users, in the case 8 pepole. but i need it to were they can only edit there cells and no one else. -- wally0206 ------------------------------------------------------------------------ wally0206's Profile: http://www.excelforum.com/member.php...o&userid=14995 View this thread: http://www.excelforum.com/showthread...hreadid=546100 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
cell edit by user
"wally0206" wrote in
message ... I have a workbook that is used by more then one users, in the case 8 pepole. but i need it to were they can only edit there cells and no one else. -- wally0206 ------------------------------------------------------------------------ wally0206's Profile: http://www.excelforum.com/member.php...o&userid=14995 View this thread: http://www.excelforum.com/showthread...hreadid=546100 I think Microsoft is contemplating such feature for a future release of Excel, but for now I can only offer of a rough solution: 1) Protect the sheet with password. This password is YOUR password (you will need it to protect/unprotect the sheet with VBA) 2) Write an AutoOpen macro, that would do the following when the user opens the workbook: a) Unprotect sheet, lock all cells, protect sheet again b) Show an Inputbox,into which each user has to input HIS/HER password (you have to inform each of your 8 users an individual password for editing). c) If the user has entered his/her correct 'password' (it's more a barrier to for unauthorized users to execute the rest of the macro and has nothing to do with the 'real' PW used by Excel), let the macro unprotect the sheet, unlock the cells that the user is allowed to edit, then protect the sheet again. Don't forget to protect the code with a password, otherwise users can see other users password by looking at the code. Good luck. Joerg |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Attempted edit of protected cell jumps user to another cell | Excel Discussion (Misc queries) | |||
multiple user in excel to edit a userform | Excel Discussion (Misc queries) | |||
allow a user to edit ranges in a protected worksheet | Excel Worksheet Functions | |||
Protect spreadshet, but allow user edit range | Excel Programming | |||
Edit worksheet while a user form is on? | Excel Programming |