/// <summary>
/// OK Button, commit the RebarShapeDef, if there are not any exception,
/// The RebarShape will be added to Revit Document successfully.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void okButton_Click(object sender, EventArgs e)
{
try
{
m_rebarShapeDef.Commit(m_rvtDoc, GetOrCreateDefinitionGroup());
}
catch (Exception ex)
{
MessageBox.Show("Rebar shape creation failed:" + ex.ToString());
return;
}
DialogResult = DialogResult.OK;
Close();
}