The overload of GetPage which accepts an AccessLevel parameter is obsolete since CMS 5 R2 and the parameter will be ignored anyway. GetPage will return any page, you have to check the PageData.ACL (.QueryDistinctAccess for example). You'll still need the AccessLevel enum though, and your problem is probably that you don't have a reference to the EPiServer.BaseLibrary assembly.
Thanks for your reply. Yes, you are right, reference to EPiServer.BaseLibrary was missing. Problem solved!
I am unable to get EPiServer.Security.AccessLevel enum? Actually i want to use GetPage to get contents of the page. Getpage has three parameters, last parameter is EPiServer.Security.AccessLevel but AccessLevel enum is not coming. Any idea?