Quantcast
Channel: Web Forms
Viewing all articles
Browse latest Browse all 23244

command type doesn't exist in the current context

$
0
0

it ain't work , why ? i am using VS 2012 , .Net framework 4,

look at the code below (Bold) , it underlines CommandType object, and says that'It doesn't exist in the current context'. 

protected void Page_Load(object sender, EventArgs e)
    {
        String con_string = ConfigurationManager.ConnectionStrings["todolist_connectionstring"].ConnectionString;
        SqlConnection con = new SqlConnection(con_string);
        SqlCommand comm = new SqlCommand("member_login",con);
        comm.CommandType = CommandType.StoredProcedure;
    }

and yeah , i included system.data.sqlclient


Viewing all articles
Browse latest Browse all 23244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>