No announcements
Found 3741773 threads
-
2 Votes
Calling static methods from other classes
Call it with the class name, rather than an object name, as in the following: public class Class1 { public static void Method1() ...Answered | 2 Replies | 869 Views | Created by Ninami - Thursday, October 17, 2013 6:14 PM | Last reply by Ninami - Thursday, October 17, 2013 6:32 PM -
0 Votes
Call Instance Method From Static Method
*edit* After changing Instance to being static, I can now call Form1.Instance from within the same ...Answered | 4 Replies | 3185 Views | Created by mcfly1204 - Tuesday, December 6, 2011 7:27 PM | Last reply by Bob Shen - Thursday, December 8, 2011 7:11 AM -
0 Votes
Benefit of Static Class & Static Methods?
Say, you want to keep a count of how many instances of a class have been created - the only way to keep that is a static field.Answered | 2 Replies | 4760 Views | Created by GurunGuns - Sunday, August 30, 2009 11:40 PM | Last reply by codevanced - Monday, August 31, 2009 7:42 AM -
3 Votes
Static Class and methods
For instance if I had a phoneNumber class that seperates area code from the number.Answered | 10 Replies | 2041 Views | Created by LukasCs - Monday, December 19, 2011 4:02 PM | Last reply by darnold924 - Wednesday, December 21, 2011 8:05 PM -
0 Votes
All static methods in class
>I'm curious whether there's any meaningful difference between an instance class with all static methods and a static class with the same.Answered | 6 Replies | 568 Views | Created by Indurate - Thursday, April 14, 2016 10:05 PM | Last reply by Magnus (MM8) - Friday, April 15, 2016 5:12 PM -
0 Votes
How to call static method from DynamicMethod
"Long story short, how to I deal with the generic return type?Answered | 7 Replies | 2005 Views | Created by w3explorer - Sunday, November 22, 2015 12:35 AM | Last reply by w3explorer - Saturday, November 28, 2015 9:06 PM -
5 Votes
static classes and methods
You will have to work, do a lot of code to get to know where you use static and where non-static method (and classes).Answered | 7 Replies | 4207 Views | Created by Mallikharjun Kona - Friday, June 10, 2011 5:48 PM | Last reply by Mallikharjun Kona - Thursday, July 7, 2011 9:42 AM -
0 Votes
user defined class and static methods
Please read this article to know more about the static class and static ...Answered | 3 Replies | 1492 Views | Created by Shadab Hashmi - Wednesday, October 17, 2012 5:58 PM | Last reply by Sambath Raj.C - Wednesday, October 17, 2012 6:48 PM -
8 Votes
Static Method vs Non-Static Method
The basic difference is how the methods being called.Answered | 5 Replies | 29396 Views | Created by Suderson Parthasarathy - Thursday, May 6, 2010 9:40 AM | Last reply by Gopala Krishnan.V - Thursday, May 6, 2010 11:46 AM -
0 Votes
How to get the calling instance in a static method
Save the calling instance to static variable and read it from there or pass as an parameter to helper method.Answered | 2 Replies | 2828 Views | Created by RathiR - Thursday, February 16, 2012 12:28 PM | Last reply by MasaSam - Thursday, February 16, 2012 12:40 PM -
2 Votes
Calling backgroundWorker1.ReportProgress from a static method
something along the line of: class MyForm { static BackgroundWorker ...Answered | 5 Replies | 3879 Views | Created by chinook_pdx - Friday, January 14, 2011 11:04 PM | Last reply by Arik Poznanski - Saturday, January 15, 2011 7:57 PM -
1 Votes
Call Method in another Class
define the funcation static好女孩上天堂,坏女孩走四方。。。Answered | 5 Replies | 3111 Views | Created by obrienkev - Wednesday, July 21, 2010 8:51 AM | Last reply by zhaowanru19 - Thursday, July 22, 2010 2:05 AM -
8 Votes
How to call a Non Static method from the static callback function of a DependencyProperty
So you could cast it to your user control and call the non-static method.Answered | 2 Replies | 12830 Views | Created by Snnoopy33 - Saturday, April 17, 2010 2:51 PM | Last reply by Snnoopy33 - Sunday, April 18, 2010 11:35 AM -
0 Votes
static methods
Note that while there is only one definition of the static method, if it is called multiple times or from multiple places each caller will have their own stack ...Answered | 4 Replies | 1849 Views | Created by Louis Leong - Monday, March 19, 2012 4:08 PM | Last reply by Eyal Solnik - Monday, March 19, 2012 4:54 PM -
0 Votes
how call base class method from derived class method?
On 11/15/2012 6:52 PM, Steve Richter wrote: In the ToString method of the Derived class, how do I call into the ToString ...Answered | 1 Replies | 1976 Views | Created by Steve Richter - Thursday, November 15, 2012 11:52 PM | Last reply by Igor Tandetnik - Thursday, November 15, 2012 11:53 PM -
0 Votes
static methods
You can then call this method directly: ProjectANamespace.ClassA.StaticMethod(); (or add a ...Answered | 1 Replies | 948 Views | Created by love4csharp - Wednesday, January 23, 2013 5:33 PM | Last reply by Reed Copsey, Jr - Wednesday, January 23, 2013 5:38 PM -
5 Votes
get method calling class
You can get the class type directly from MethodBase.Answered | 25 Replies | 4731 Views | Created by jeremygwa - Tuesday, April 21, 2009 9:43 PM | Last reply by Rudedog2 - Friday, April 24, 2009 10:56 PM -
0 Votes
Calling an Age method from a class
Suppose you have a Dentist object called dentist1 and the date of birth in the Person class is called DOB.Answered | 2 Replies | 933 Views | Created by GG84 - Monday, April 18, 2016 8:49 PM | Last reply by DA924x - Tuesday, April 19, 2016 3:10 AM -
0 Votes
Calling a static method from another project in the solution.
I tried making it a normal class and making an instance of it to see if i could call the method.... and i got a compiler on top of the missing definition of ...Answered | 2 Replies | 6778 Views | Created by DVAz - Wednesday, September 22, 2010 6:33 PM | Last reply by Mr. Javaman - Wednesday, September 22, 2010 9:41 PM -
2 Votes
static method
"Static Classes and class members are used to create data and functions that can be accessed without creating an instance of the class.Answered | 3 Replies | 761 Views | Created by Jeff0803 - Tuesday, February 4, 2014 6:18 PM | Last reply by Jeff0803 - Thursday, February 6, 2014 4:54 PM - Items 1 to 20 of 3741773 Next ›
No announcements