Create a Database e.g. "MyDataBase" and a table under that DataBase in Sql Server and name it "EMPLOYEE" as shown in figure:

Click on image to enlarge

Note: EMP_ID column is set to Primary key and Identity specification is set to yes with Identity increment and Identity seed equal to 1. Insert some data in this table that you want to show in the Gridview.

Now Create a stored procedure
in sql server as:

CREATE PROCEDURE
GET_EMP_DATA

AS

BEGIN

SELECT
* FROM EMPLOYEE

END

Now in web.config file add the connectionstring under <configuration> tag :

Related Post

If you have any question about any post, Feel free to ask.You can simply drop a comment below post or contact via Contact Us form. Your feedback and suggestions will be highly appreciated. Also try to leave comments from your account not from the anonymous account so that i can respond to you easily..
ConversionConversionEmoticonEmoticon