Password or name not recognised


I have reinstalled 10.6 from the DVD on a hdd (without erasing) but found that after booting the system was locked against all changes. When I typed name and password at the prompt all I got was the message 'You must type an administrator's name and password to make changes to system preferences'
I have been back to the install DVD and reentered the password twice but it made no difference. I used disk utility from another disk to repair permissions (needed) and also repair disk (unnecessary). I also reaffirmed my password using disk utility. I want to update the software but now when i click the padlock sign and enter the name and password I just get 'Try entering your information again'.
How do I get round this without erasing the disk and stating all over.
Many thanks