Thanks very much, I probably should have searched harder, I will try it out!
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
Thanks very much, I probably should have searched harder, I will try it out!
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
Thanks Mark for your information. I did a little bit of research on the method you provided me, and I found out this Intersect() method belongs to a GDI+ rectangle structure and it's not supported in WPF shapes. Are there any other methods which can substitute this one? BTW, you are right about what I am looking for. In my program, I need to use an event to detect the intersection of different WPF UI elements in order to process some task once they cross over with each other.
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
I need to define a customized event which detects whether the border of one UI element crosses the border of the other UI element. Make this assumption that both UI elements are on a Canvas, and they have the relative coordinates toward the boundary of the Canvas which are Canvas.Left and Canvas.Bottom. My initial thought was to create a function which checks the relative coordinates of these two elements and raise the event whenever their coordinates are identical. Then, I realized it was rather awkward because each element has its area and it can not be considered as a pixel. I have contemplated this puzzle for quite some time but still I can not come out with anything. Would anyone be kind enough to help me out on this I will be grateful. Thanks in advance
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
Surely. Hee, Hee.
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
Errr... I only supposed that I partially understand your question. But, after referred to others' posts, I guess what you were trying to do was merely certain issues of "namespace" that you misunderstood. In general, a .NET namespace provides a way to encapsulate your classes, delegates, structures, enumerations etc. Meaning, anything you create or implement ought to ultimately exist in namespaces. In such a manner, a project doesn't really suggest an individual object which you can reference to; it merely groups whatever namespaces needed and manipulate the members existing in a pre-defined sequence. Thus, for your question, you define a public enumeration in project A which subsequently defines "namespace A"; in order to make use of the enumeration, you have to reference the "namespace A" in whatever post projects you create. Hope it's helpful. Ray -- modified at 22:51 Thursday 15th November, 2007 -- modified at 22:52 Thursday 15th November, 2007
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;
Hey, the 'new' keyword is to explicitly hide the base class members But, if you want to use it, you have to call the method from the derived class. In this case you surely need to create a reference of the derived class other than a original base class reference. Since you have already created the Program object to a user reference, all you need to do is to perform a cast: (Program)u.print(); regards
Someone was born greatness; Someone achieved greatness; Someone let the greatness thrust upon him;
Thanks for all...:-D
Someone was born greatness; Someone achieved greatness; Someone let the greatness thrust upon him;
Dunbar C wrote:
You can create some applications without thinking too much more, just let them run with simple features, such as IO, Registry, Graphics, etc. These can help you with further programming.
Thanks very much for your suggestion. But, if I could choose to start from all the fundamentals I would REALLY not put myself into this situation:).
Dunbar C wrote:
Since then, you shoule know this way: you can use XML document to save the user configuration and let the application "read" the user's settings and "implement" them. Use XML to store and read user configruation. That's "what you do", not "how to do".
I did read about that the C# (or maybe the .NET framework) supports the *.resx file format which is to persist all the external resources used for an application. However, upon what I read I haven't figured out how to modify a resource file at real-time. And yes, the resource file is making use of the XML file. Is it what you were just trying to say?
Someone was born greatness; Someone achieved greatness; Someone let the greatness thrust upon him;
As I know, a real application has the ability to let users to change certain settings and alter the way the application runs, which is regarded as user configuration. Some settings will take the effect immediately after you click 'OK' while the program is running, some may request you to restart the program I am a complete novice for programming, though I have read so many text books about C#. All I know now is that like how to create classes, structures, define functions, callbacks, delegates, interfaces, declare variables and so forth. I totally have no idea about how to design a real application from scratch although I was thrown in this situation that I have to. I have partially completed the flowchart but I still don't understand how to persist and implement user configurations to make the application interactive? Thanks for anyone could give me some hints. -- modified at 23:13 Tuesday 25th September, 2007
Someone was born greatness; Someone achieved greatness; Someone have the greatness thrust upon him;