by Luis de Vasconcelos.
What $CFG->dbhost have you got in your config.php file?
And which PHP MSSQL extension are you using - SQLSRV (Microsoft PHP driver) or MSSQL (FreeTDS).
What are you using that "LocalSqlServer=datasource..." connection string in IIS for? Moodle gets the database connection details from the config.php file, so you don't need to create connection strings in IIS.