Hi,
**Method 1:**I would suggest you to perform SFC scan and check if it helps. To do so, please refer to the following article. The SFC /scannow command scans all protected system files and replaces incorrect versions with correct Microsoft versions. For more information how to do SFC/ scan, please follow this link:
http://support.microsoft.com/kb/929833
You may refer the following link for more information.
Method 2: Let’s create a new Windows user account and then try to install Java check if this issue occurs with the new user account. Refer the link to create a new user account.
‘Create a user account’
http://windows.microsoft.com/en-US/windows7/Create-a-user-account
If the issue does not exist in new user account then, try to fix the corrupted profile follow the steps mentioned in the following article.
Fix a corrupted user profile
http://windows.microsoft.com/en-US/windows7/Fix-a-corrupted-user-profile