Code: Select all
private void UpdatePlatypus(String APetPlatypus)
{
oracleConnectionMainForm.Open();
OracleCommand ocmd = new OracleCommand();
ocmd.Connection = oracleConnectionMainForm;
try
{
ocmd.CommandText = @"<Update SQL statement that contains one parameter, like so: "WHERE DUCKBILLEDPLATYPUS = :PLATYPUS">)";
ocmd.Parameters.Add("PLATYPUS", APetPlatypus);
ocmd.ExecuteNonQuery();
}
catch (Exception e)
{
MessageBox.Show(String.Format("UpdatePlatypus failed with message {0}", e.Message));
}
finally
{
oracleConnectionMainForm.Close();
}
MessageBox.Show(String.Format("UpdatePlatypus to {0} succeeded", APetPlatypus));
}
But in my C# app, it hangs on the call to ExecuteNonQuery()...I never see any of the messages - neither that the Update failed, nor that it succeeded - it simply hangs there, floating about in space like a smurf ball on the moon.