SELECT *
FROM ::fn_trace_gettable(
'C:\Program Files\Microsoft SQL Server\MSSQL10.SQLSERVER2008\MSSQL\DATA\audittrace20100707161605.trc', default
)
GO

Venkatesan Prabu MCITP,MCAD,MCTS,CCNA. Worked as a ProjectLead(Senior .Net developer,SQL DBA). Now, Managing Director of KAASHIV INFO TECH, Chennai This Blog aims in serving the community in a better way. This blog is read by developers in 159 countries with average of 400 hits per day. Please post your valuable suggestions and hold my hand to serve the community. Lets make a new world with good thoughts and good minds....... This blog serves the SQL server community all over the world.
While trying to use windows application, I got a peculiar timout error.
SqlCommand cmd = new SqlCommand("My_Report_Proc", conn);
cmd.CommandType = CommandType.StoredProcedure;
//dataGridView1.DataSource = cmd.ExecuteReader();
// bind the data source to the datagrid
//dataGridView1.databind();
// close the connection to the database since we are done using it
DataSet ds = new DataSet();
SqlDataAdapter da = new SqlDataAdapter(cmd);
da.Fill(ds); --Got the error at this point
dataGridView1.DataSource = ds.Tables[0];
Error string:
Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding in windows appilcation
I have tried adding connection timout (Connect Timeout=500;). Still, the problem is not resolved. After wards, I have added the command cmd.CommandTimeout = 0; This issue is resolved.