Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / Design Time / August 2004

Tip: Looking for answers? Try searching our database.

Custome Form Designer: How to implement undo/redo

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Tian Qiang Chen - 13 Aug 2004 09:26 GMT
Hi,
I got the sample code "DesignerHost" from "INFO: Code Sample That
Demonstrates How to Create a Custom Form Designer by Using Visual C# .NET"
http://support.microsoft.com/default.aspx?scid=kb;en-us;813808.
The sample code has no these features "copy, cut, paste, undo and redo", I
wanna implement them. After seaching on internet, I got the result" to
implemnt copy, cut, paste, you must implement IDesignerSerializationService
and add this service. I wrote a SampleDesignerSerializationService.cs, the
sample has copy,paste and cut features.

Now I such on implmenting undo/redo feature. In the sample code, the
copy/paste command is added by default when System.Windows.Forms.Form is
created. Using "MenuCommandSerice.GlobalInvoke" can call the copy/past
functions. But the undo and redo standard commands is not added by default.
I want to know which attribute should be added on the form, I can invoke the
undo/redo function.

And I am not sure, whether any other service should be add to the
DesignHost, The the undo/redo feature can works.

Thanks

Tian Qiang
Yap We Kwang - 25 Aug 2004 09:48 GMT
Hi Tian
       Could you show me how to you implement IDesignerSerializationService in you custom class SampleDesignerializationService.cs? I also implemented my own custom IDesignerSerializationService class which has two methods-- that are Serialize and Deserialize. Is that need to add host.createComponent() in Deserialize method and host.Container.Add() in Serialize method? I'm very appreciate your help if you can give me some guide on what thing need to do in this both method. Many thanks
             

---

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.