public string CreateDialog(string caption, int x, int y, int w, int h) { //create a new dialog ClassDialog cd = new ClassDialog(caption, x, y, w, h); dialogs.Add(cd); System.Diagnostics.Debug.WriteLine("Created:" + cd.Handle); //the dialog handle / ID is the windows handle return(cd.Handle.ToString()); }
/* * public void AddComboBox(string dialogID, int x, int y, int w, int h, string id) * { * ClassDialog cd = dialogs.Find( * delegate(ClassDialog c) * { * return c.Handle.ToString() == dialogID; * } * ); * * if (cd != null) * cd.AddControl(5, "", x, y, w, h, id, ""); * } */ public void AddComboBox(string dialogID, int x, int y, int w, int h, string id, int style, string controlName) { ClassDialog cd = dialogs.Find( delegate(ClassDialog c) { return(c.Handle.ToString() == dialogID); } ); if (cd != null) { cd.AddControl(5, "", x, y, w, h, id, controlName); } }
public void AddLabel(string dialogID, string caption, int x, int y, int w, int h, string id) { ClassDialog cd = dialogs.Find( delegate(ClassDialog c) { return(c.Handle.ToString() == dialogID); } ); if (cd != null) { cd.AddControl(3, caption, x, y, w, h, id, ""); } }
public void CloseDialog(string dialogID) { ClassDialog cd = dialogs.Find( delegate(ClassDialog c) { return(c.Handle.ToString() == dialogID); } ); if (cd != null) { cd.Close(); } }
public void RemoveDialog(string dialogID) { ClassDialog cd = dialogs.Find( delegate(ClassDialog c) { return(c.Handle.ToString() == dialogID); } ); if (cd != null) { dialogs.Remove(cd); } }
public void AddCheckBox(string dialogID, string caption, int x, int y, int w, int h, int id, int style, string controlName) { // id == 0 -- no need for it ClassDialog cd = dialogs.Find( delegate(ClassDialog c) { return(c.Handle.ToString() == dialogID); } ); if (cd != null) { cd.AddControl(6, caption, x, y, w, h, "", controlName); } }
public string CreateDialog(string caption, int x, int y, int w, int h) { //create a new dialog ClassDialog cd = new ClassDialog(caption, x, y, w, h); dialogs.Add(cd); System.Diagnostics.Debug.WriteLine("Created:" + cd.Handle); //the dialog handle / ID is the windows handle return cd.Handle.ToString(); }