MySQL Error : 1045

1. Run Server ( WAMP / XAMPP )

2. Click on it in System Tray ( Right-Down corner of window )

3. MySQL > MySQL console

4. Type password and hit Enter 
or, If u don't have any just hit Enter 

5. If the screen shows, 
Welcome to the MySQL monitor. ...
then u have rightly entered in MySQL

6. Write the following commands sequentially,
mysql> use mysql
mysql> select user, host, password from user;
mysql> delete from user where host='localhost' and user='';
mysql> update user set password=password('') where user='root';
mysql> flush tables;
mysql> flush privileges;
mysql> quit

// all quotes are single quotes