示例#1
0
        private static Whiteboard CreateStructure()
        {
            Whiteboard w = new Whiteboard();
            w.EnableDeletion = true;
            w.EnableFiltering = true;
            w.EnableHeaders = false;
            w.Name = "Whiteboard1";
            w.PageSize = 8;

            Whiteboard.Column c1 = new Whiteboard.Column();
            c1.Caption = "Patient";
            c1.Position = 0;
            c1.Type = "InPlaceEdit";
            w.Columns.Add(c1);

            Whiteboard.Column c2 = new Whiteboard.Column();
            c2.Caption = "Doctor";
            c2.Position = 1;
            c2.Type = "InPlaceEdit";
            w.Columns.Add(c2);

            w.Save();
            return w;
        }
        protected void CreateNewWhiteboard(object sender, ActiveEventArgs e)
        {
            // Closing window...
            ActiveEvents.Instance.RaiseClearControls("dynPopup");

            string name = e.Params["WhiteboardName"].Get<string>();
            Whiteboard w = new Whiteboard {Name = name};
            w.Save();

            // Open whiteboard that was just created...
            EditWhiteboard(w.ID);

            RefreshMenu();

            ActiveEvents.Instance.RaiseActiveEvent(
                this,
                "WhiteboardWasCreated");
        }