RE: static function question
- From: "Salvador" <Salvador@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 19 Apr 2005 05:19:03 -0700
Hi,
Can you post the code, remember that you should call the object using the
class name and not the instance to access the static ones:
public class MyStaticClass
{
public static int StaticVar;
public int InstanceVar;
}
// To access the static one
MyStaticClass.StaticVar;
//To access the instance one
MyStaticClass MyInstance = new MyStaticClass();
MyInstance.InstanceVar;
Cheers
Salva
"juli jul" wrote:
> Hello!
> If I want to pass some class variable from one class to another : how
> can I do it with the static function?
> I tried but I can't see the class variables in the static function I
> made-are there some other methods to do it?
> Thank you!
>
> *** Sent via Developersdex http://www.developersdex.com ***
>
.
- References:
- static function question
- From: juli jul
- static function question
- Prev by Date: keyed-MD5 Implementation
- Next by Date: Re: static function question
- Previous by thread: static function question
- Next by thread: Re: static function question
- Index(es):
Loading