Click here to Skip to main content
15,912,977 members
Home / Discussions / C#
   

C#

 
AnswerRe: Middle mouse click and scroll Pin
gwithey31-Jul-09 1:27
gwithey31-Jul-09 1:27 
GeneralRe: Middle mouse click and scroll Pin
Luc Pattyn31-Jul-09 1:38
sitebuilderLuc Pattyn31-Jul-09 1:38 
GeneralRe: Middle mouse click and scroll Pin
Baeltazor31-Jul-09 7:35
Baeltazor31-Jul-09 7:35 
GeneralRe: Middle mouse click and scroll Pin
gwithey2-Aug-09 20:51
gwithey2-Aug-09 20:51 
Questiondata synchronization between two client machine over the internet by Webservice? Pin
Tridip Bhattacharjee31-Jul-09 0:41
professionalTridip Bhattacharjee31-Jul-09 0:41 
AnswerRe: data synchronization between two client machine over the internet by Webservice? Pin
Dave Kreskowiak31-Jul-09 4:51
mveDave Kreskowiak31-Jul-09 4:51 
QuestionHow to know toolbar got clicked through a BHO (C#)? Pin
svt gdwl31-Jul-09 0:05
svt gdwl31-Jul-09 0:05 
Questioncode for updating datatable. Pin
Omar Akhtar Sheikh30-Jul-09 23:46
Omar Akhtar Sheikh30-Jul-09 23:46 
// please anyone could help me write the update code

public DataTable GetCustomers()
                  {
                           string query = "SELECT * FROM Customer_2";
                           SqlDataAdapter da = new SqlDataAdapter(query, constr);
                           DataTable table = new DataTable();
                           da.Fill(table);
                           return table;

                  }

                  // For Inserting Customers
                  public void InsertCustomer(string customerName)
                  {
                           string query = "INSERT INTO Customer_2 (CustomerName) VALUES (@CustomerName)";
                           SqlConnection con = new SqlConnection(constr);
                           SqlCommand com = new SqlCommand(query, con);
                           com.Parameters.Add("@CustomerName", SqlDbType.NVarChar).Value = customerName;
                           con.Open();
                           com.ExecuteNonQuery();
                           con.Close();
                  }


                  // For Deleting Customers

                  public void DeleteCustomers(List<int> customerIDsToDelete)
                  {
                           string query = "DELETE FROM Customer_2 WHERE CustomerID = @CustomerID";
                           SqlConnection con = new SqlConnection(constr);
                           SqlCommand com = new SqlCommand(query, con);
                           SqlTransaction tr = null;

                           try
                           {
                                    con.Open();
                                    tr = con.BeginTransaction();
                                    com.Transaction = tr;
                                    com.Parameters.Add("@CustomerID", SqlDbType.Int);

                                    foreach (int item in customerIDsToDelete)
                                    {
                                             com.Parameters["@CustomerID"].Value = item;
                                             com.ExecuteNonQuery();
                                    }
                                    tr.Commit();
                           }
                           catch (Exception ex)
                           {
                                    tr.Rollback();
                                    throw ex;
                           }
                           finally
                           {
                                    con.Close();
                           }
                  }


// please anyone could help me write the update
AnswerRe: code for updating datatable. Pin
Not Active30-Jul-09 23:51
mentorNot Active30-Jul-09 23:51 
JokeRe: code for updating datatable. Pin
Nagy Vilmos31-Jul-09 0:01
professionalNagy Vilmos31-Jul-09 0:01 
GeneralRe: code for updating datatable. Pin
PIEBALDconsult31-Jul-09 4:55
mvePIEBALDconsult31-Jul-09 4:55 
AnswerRe: code for updating datatable. Pin
PIEBALDconsult31-Jul-09 4:54
mvePIEBALDconsult31-Jul-09 4:54 
AnswerRe: code for updating datatable. Pin
Adam R Harris31-Jul-09 8:05
Adam R Harris31-Jul-09 8:05 
GeneralRe: code for updating datatable. Pin
Omar Akhtar Sheikh31-Jul-09 8:27
Omar Akhtar Sheikh31-Jul-09 8:27 
GeneralRe: code for updating datatable. Pin
Adam R Harris31-Jul-09 9:16
Adam R Harris31-Jul-09 9:16 
General[Message Deleted] Pin
Omar Akhtar Sheikh31-Jul-09 11:56
Omar Akhtar Sheikh31-Jul-09 11:56 
GeneralRe: code for updating datatable. Pin
Adam R Harris31-Jul-09 12:14
Adam R Harris31-Jul-09 12:14 
QuestionProblem in Filter Grid Pin
SwastikInfosystems30-Jul-09 23:29
SwastikInfosystems30-Jul-09 23:29 
AnswerRe: Problem in Filter Grid Pin
OriginalGriff30-Jul-09 23:54
mveOriginalGriff30-Jul-09 23:54 
AnswerRe: Problem in Filter Grid Pin
stancrm30-Jul-09 23:55
stancrm30-Jul-09 23:55 
AnswerRe: Problem in Filter Grid Pin
Nagy Vilmos30-Jul-09 23:59
professionalNagy Vilmos30-Jul-09 23:59 
QuestionProblem in Filter Grid Pin
SwastikInfosystems30-Jul-09 23:17
SwastikInfosystems30-Jul-09 23:17 
AnswerRe: Problem in Filter Grid Pin
Vimalsoft(Pty) Ltd31-Jul-09 0:06
professionalVimalsoft(Pty) Ltd31-Jul-09 0:06 
Questiongive me a code for disable keyboard functions this project............ [modified] Pin
Member 423560130-Jul-09 22:28
Member 423560130-Jul-09 22:28 
AnswerRe: Add to disable keyboard functions this project............ Pin
OriginalGriff30-Jul-09 23:16
mveOriginalGriff30-Jul-09 23:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.