How to access the Property value of nested class in c# -


i have following code in assembly.

      public class     {         public class b         {             public static string obj;             public static string result             {                                 {                     return obj;                 }                 set                 {                     obj = value;                 }             } }             public class c             {                 string result1;                 public void invoke()                 {                     result1 = "abc";                     b.result = result1;                 }               }         } 

i had referenced in application(say eg: client app) , trying access value of obj

if invoke value creating instance of class b how can access value set in previous scope without return invoked method?

since involved public, can access value outside assembly follows:

public class someexternalclass {     public void somemethod()     {         string val = a.b.result;     } } 

Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -