|
How can I use the mouse event to move object
|
|
|
|
|
search CodeProject articles for movable controls
|
|
|
|
|
Whenever I try to add new functions or method via Class Diagram,
VS always insert this code:
throw new System.NotImplementedException();
1. What kind of exception is this and what is it's use?
2. How can I configure VS to not generate this code?
Thanks a lot.
|
|
|
|
|
The exception does exactly what it says on the tin. It is used where a method that should be implemented isn't, presumably so that you don't forget to implement the method. I don't know if you can change a setting to make it not show up, in my opinion, doing so could make it very easy to forget to implement a function, leading to potentially hard to diagnose bugs.
|
|
|
|
|
So I will just have to delete it if I'm going to right code inside the function?
|
|
|
|
|
Unless you want your code to throw a NotImplementedException, yes.
|
|
|
|
|
Sorry, I'm kinda new to the term. What do you mean by "implementing the function", using it in a program or adding functionality in it?
|
|
|
|
|
He means: write the code for your function and delete the line:
throw new System.NotImplementedException();
Unless you have a very good reason to keep it there.
|
|
|
|
|
If I write a code for the function, then what will be an example of a good reason to leave that there?
|
|
|
|
|
It's difficult to say, because once you've got the function written, it's been implemented. However, you could be writing a plugin-based application. The plugin base class could look something like this:
public abstract class PluginBase
{
public string Name { get; set; }
public virtual void Activate<T>(T input)
{
throw new System.NotImplementedException("This base class method must be overriden by a plugin");
}
}
|
|
|
|
|
Ok. I understand now. Thanks.
|
|
|
|
|
Of course not. You know how you want your code to be, right? Make it so. If that includes throwing a NotImplementedException then so be it.
|
|
|
|
|
This may not be the best forum to post, but I am using C#.
I add a Special field: »Page N to M«. But I want to have a text in different language: »Stran: N od M«
Thanks in Advance
|
|
|
|
|
I am not sure whether this will work but if you can load this field dynamically from C# (or .NET) do the following:
1) Create a resource file
2) add the field name and text
3) use this in the code instead of the hard coded string
4) Add another resource file with the culture name inbetween the file name and the .resx (e.g. myResource.resx will become myREsource.fr-FR.resx)
5) Copy the exact field to the second file
6) Write it in your language
7) Change the appplication culture to the resx culture
|
|
|
|
|
Thank you, will try later
|
|
|
|
|
Hi all i need helping of ...
how to send a TCP & UDP packets using Socket class........
Regards................................
|
|
|
|
|
I am working in a project implemented in COM (ATL)where , my class derives from app 12-14 classes.
Now while implementing the same class in C#, i am facing problem (as C# not support multiple inheritance).
Can you please provide me the ways we can archive multiple inheritance in .net.
|
|
|
|
|
Message Closed
modified 23-Nov-14 6:58am.
|
|
|
|
|
stancrm wrote: There are no multiple inheritance in C#.
Correct.
stancrm wrote: But this is the answer :
No it isn't.
|
|
|
|
|
|
It sounds like the old application was poorly designed, rewrite it.
|
|
|
|
|
Hello,
i need to capture the contents(text) of the selected application from listbox that contains all running applications. If its MDI application then all opened child application contents should also be captured.
The captured text should be store in text file.
I little bit know about windows api such as user32.dll has functions like getwindowtext(), findwindow(),etc.
Will it be help to me? Can i get the whole running application window text?
Please help me for this.
Thank you in advance.
|
|
|
|
|
I really believe that it is simply possible to use API for capturing Text. I think the only way to achieve this is to read memory address of a process.
|
|
|
|
|
Thank you for your reply,
I just need to verify that is it possible to capture any length of text
And one more thing only editable applications are captured or non editable are also?
Thank you in advance.
|
|
|
|
|
krinaljariwala wrote: I just need to verify that is it possible to capture any length of text
Yes, it is:
krinaljariwala wrote: And one more thing only editable applications are captured or non editable are also?
All data is capture able, as long process holds it in memory. Now in question is: Is it encrypted, Where is it and does memory location changes every time the process is started. If there isn't other way, you would need to look into how to decompile, study ASM and maybe even Inject your own ASM code into another process. Some process will have anti-debug protection. Note that this can go against law. It all depends on what kind of data you are attempting to get. Part of this process is called Reverse Engineering. If it is your App, then I suggest you build some come interface to communicate, if not then there are 2 options: Contact developers of that application or try and build it. If you start memory hacks. It's memory location would only work with specific process with same version.
If you want to capture users output, maybe simple API to get key pressed on keybeard. Like KeyLoggers do.
Also I noticed WinAPI has GetText. Maybe is that what you are looking
modified on Saturday, December 5, 2009 7:43 AM
|
|
|
|