I'm assuming that you've tried the following: 1) Open the multitask bar (double tap home button), move to the left end and see if the screen setting is locked; 2) Go into settings and change the side switch back & forth between sound vs. screen lock - retest?
If those maneuvers do not help and if not already done, 'Restart' and if not successful 'Reset' the iPad - directions HERE, if needed. Good luck and please post back here if assistance is still needed!