方法有二
1.直接修改TEXT:
View Code
this.Text = "csg - " + FullFileName;
2.通过调用DLL文件修改:
方法二
#region 方法二 docManagerData.NewDocName = FullFileName; docManager = new DocManager(docManagerData); docManager.RegisterFileType("csg", "csgfile", "DrawTools File");//文件关联 // Subscribe to DocManager events. docManager.SaveEvent += docManager_SaveEvent; docManager.LoadEvent += docManager_LoadEvent; // Make "inline subscription" using anonymous methods. docManager.OpenEvent += delegate(object sender, OpenFileEventArgs e) { // Update MRU List if (e.Succeeded) mruManager.Add(e.FileName); else mruManager.Remove(e.FileName); }; docManager.DocChangedEvent += delegate { drawArea.Refresh(); drawArea.ClearHistory(); }; docManager.ClearEvent += delegate { bool haveObjects = false; if (drawArea.Graphicslist.Count > 1) { haveObjects = true; } if (haveObjects) { drawArea.Graphicslist.Clear(); drawArea.ClearHistory(); drawArea.Refresh(); } }; docManager.NewDocument(); #endregion