|
No Need
SSK.
Anyone who says sunshine brings happiness has never danced in the rain.
|
|
|
|
|
If .net frame work handles this...Y should I write destructors manually in some cases and
Regards,
Sivaprasad
|
|
|
|
|
|
And how does this answer his question?
|
|
|
|
|
.NET does not have the same concept of destructors as C++ does. The ~T syntax (for C#) you see (where T is the name of the class) is actually a finalizer. You should almost never need to write a finalizer.
What you are probably thinking of is a Dispose method or the IDisposable interface. Really the only time you need to use this in your own class is when you are managing native resources (unmanaged memory) yourself or you are internally managing a class that implements it.
There are a lot of references available, both here on CP and the web. You can check out this article[^] for more information.
|
|
|
|
|
hi
how to call base class constructor from derived class
how to do it?
not by instantiaze the base class object..
thanks in advance
|
|
|
|
|
To kalyan_2416,
Take a look at the following sample.
public abstract class BaseClass
{
public BaseClass()
{
Console.WriteLine("Invoke from base class.");
}
}
public class DerivedClass : BaseClass
{
public DerivedClass()
: base()
{
Console.WriteLine("Invoke from derived class.");
}
}
class Program
{
static void Main(string[] args)
{
new DerivedClass();
}
}
---------------------------output--------------------------
Invoke from base class.
Invoke from derived class.
---------------------------------
Believe what you saw!
|
|
|
|
|
I am new in c# programming,i want to improve my programming ability,how?
|
|
|
|
|
A says like this : Practice makes perfect.;P
---------------------------------
Believe what you saw!
|
|
|
|
|
You need to study and gain experience. Being the "top" in anything takes time and hard work.
|
|
|
|
|
Hello Dears
Subject: Want to Disappear Context menue strip
I made a window service controller which are in system tray (sqlservier controler in system tray) , right click on symbol of (Controller)
the context menue strip is appear.... and show some menue like show, Exit etc...
now the problem is that if i click any where in desktop it should disapear but in our case it is not....
Now i Want to Disappear Context menue strip when i click any where on desktop except Context menue strip.....
Sooperfellow
-- modified at 2:15 Wednesday 26th September, 2007
Afridi
-- modified at 2:17 Wednesday 26th September, 2007
|
|
|
|
|
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;
|
|
|
|
|
As you mentioned, you're a newbie in C#, so I think the most important thing to you is not the application interative but how to create a real application.
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.
YouMiss wrote: but I still don't understand that how to persist and implement user configurations to make the application interactive?
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".
---------------------------------
Believe what you saw!
|
|
|
|
|
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;
|
|
|
|
|
YouMiss wrote: 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?
.resx file is mostly like a file stores base 64 string of images or the extra infos of design mode of a form, and as default it's build as "Embedded Resource" in VS2005 (see the properties of one form, there is a "Build Action" node at the properties window). If you want to read and write the use configuration, a good way is to use .xml file or .config file, the select the "Build Action" as "Content", and the property "Copy to Output Direactory" as "Copy if newer".
---------------------------------
Believe what you saw!
|
|
|
|
|
Take a look at the System.Configuration namespece (mostly within the System.Configuration.dll assembly) as this contains everything you need to read and write configuration settings for an application.
|
|
|
|
|
Thanks for all...
Someone was born greatness;
Someone achieved greatness;
Someone let the greatness thrust upon him;
|
|
|
|
|
I am interested in designing a custom Form skin. I have seen several articles in the Code Project concerning the use of the skin, but I haven't seen much concerning the tools and techniques to make a good skin. Thanks in advance for your help.
HossFly
|
|
|
|
|
Have you asked the article authors? Post them a message at the bottom of their article's forum and they might help you.
"Try asking what you want to know, rather than asking a question whose answer you know." - Christian Graus
|
|
|
|
|
Hello
I have this error in my project
unable to copy file "obj\Debug\systeme gharzolhasane.exe" to "bin\Debug\systeme gharzolhasane.exe". The process cannot access the file 'bin\Debug\systeme gharzolhasane.exe' because it is being used by another process. systeme gharzolhasane
Please help me
Thanks a lot
Malkan
You are winif you want
You are win if you want
|
|
|
|
|
Use task manager to see if there is another copy of devenv running. Happens sometimes when exit from debugger is not clean.
|
|
|
|
|
Hi Rob
Thanks for your help
I have a question.
What's the meaning of DEVENV in your sentence.Because ay native language is not English.
BEST REGARDS
You are win if you want
|
|
|
|
|
The DEV elopment ENV ironment - Visual Studio, or which ever IDE you are using.
Basically, something is keeping a previous instance of your application running. If you can't see it in taskmanager, download Process Explorer[^] from SysInternals (now Microsoft owned) and search for your module name. You can then kill it directly, or kill the task that is holding it open
"More functions should disregard input values and just return 12. It would make life easier." - comment posted on WTF
"This time yesterday, I still had 24 hours to meet the deadline I've just missed today."
|
|
|
|
|
Hi everyone, i would like to know if there's anyway I can detect a key pressed.
I know there exists the KeyDown and KeyPress events on every control, but i would like to know if theres any way I can detect these events in general, instead of checking these events on all the controls of my application.
I'm using a Parent Mdi Form containing lots of child forms, and of course this forms have lots of controls as well. I tried to apply this on the Parent Form's key events, but nothing.
I bet there's a simple way to get this done. Please help.
Thanks a lot for your time folks.
daniel
|
|
|
|
|
hi daniel,
for each form u have a property called kypreview, make this as true
and then add keypress or keydown event to that form,
so all the key press event come that function first and then goes to corresponding control
i hope this will solve ur problem
With Regards
Amjath
|
|
|
|