Many times user have complained that when they try to access the iPhoto Library, they get an error message that says "The iPhoto Library is locked on a locked disk, or you don't have permission to make changes to it." There are number of reasons for these kinds of error messages. Some of the possible causes are:
Two copies of iPhoto are trying to access the same library
It is possible that the iPhoto Library is stored over a server and accessed over a network such as through file sharing from another machine or a network disk like Airport Extreme, Time Capsule, NAS drive or other. So you need to be sure that no other machine in that network is accessing the iPhoto Library. The iPhoto is designed to only allow a library to be open in one copy of iPhoto at a time so if you have open the library on one computer, you first required to quit iPhoto on that machine before you can open the same library on another system.
You don't have sufficient permissions to open the library
iPhoto is programmed in such a way that you must need to have the permission of read and write to the library in order to open the library. It does not matter if you just want to open the library but without having the correct permission you will not even see the library content because the read only permission is not sufficient.
If your library is over a read only media like CD or DVD or on a USB stick with read only mode, you will not be able to access the iPhoto Library directly from that disk. To open the library the first thing that you need to do is to copy the iPhoto Library on a hard drive where it can be modified and then add that copy to iPhoto Library Manager with the help of Add Library button. After that you can view that copy of library.
In case the iPhoto Library is over the network disk using Time Capsule, Airport Extreme or NAS drive, make sure that you have the user account with write permission to access lock album iPhoto. You need to have the write permission to access iPhoto Library. Like if you are using the guest account then it is pretty obvious that you only have the read permission and not the write permission.
If the library is on the internal hard drive but is owned by other user that you are currently logged in as you may need to log in as the owner of the library change permissions on it so that other user of that system have the write permission to it. While doing these steps if you feel that something goes wrong and the library is not accessible at all and looks like corrupted then with the help of iPhoto Recovery you can recover the corrupted locked library too.