I used static member in class and reference to assembly, in sperate files I got error, Is there anyway to solve it?

Thanks for your recommendation~
but it comes new error message
redefinition of 'int MyClass::MyVariable'
or what you mean is to leave this static member in global environment?

and I found that , the public member can be private or protected, if assign as public, it will be error as I try to.
new I have two way to do,

  1. put static member to private, and add function call in public to access that static member
  2. put static member to private, then add a variable pointer in public, in this case main program can access the static member in data pointer way..
    I just wandering is anyway to keep static member public in sperate file?