Hi,
Got a solution for this one. The code above initializes everything except for one object reference that is SelectCommand . To initialize it we have to pass a command object to the reference of SelectCommand. Sadly it isnt possible to do so through DataAdapter. But still it works fine without it by just allocating the reference of SelectCommand to your command object.
Thank You....
User Profile
Collapse
-
DataAdapter Connection Problem
Hi,
I am trying to run the following code -:
DataAccess Layer Function-:
public DataSet getContacts(str ing Country, string Product)
{
DataSet dsContact = new DataSet();
dsAdapter = new SqlDataAdapter( );
string conString= ConfigurationSe ttings.AppSetti ngs["ConnectionStri ng"];
mySqlConn = new SqlConnection(c onString);
mySqlConn.Open( );
dsAdapter.Selec tCommand.Connec tion...
No activity results to display
Show More
Leave a comment: