This video should help.
https://www.youtube.com/watch?v=ttvFDFqH5r0
If you do not want to loose your pics and files then you can log in with your google account that you have assigned on the tablet from a computer and use Android device manager to lock the device with a new code and then you will be able to unlock it. Hope this is helpful.
https://www.google.com/android/devicemanager