.net - Accessing Host property from external assembly -


i'm importing external assembly of mine in t4 template using assembly processor directive.

from within said assembly, i'm trying access host property. unfortunately can't seem able to.

i tried getting host way:

public class mytransformation : texttransformation {      // ...      public void somemethod()     {         object host = gettype().getproperty("host").getvalue(this);          if (host != null)         {             // stuff         }     } } 

unfortunately, although reflection seems map property, returned value null.

the calling template file has hostspecific property set true in template directive.

what doing wrong?


Comments

Popular posts from this blog

Fail to load namespace Spring Security http://www.springframework.org/security/tags -

sql - MySQL query optimization using coalesce -

unity3d - Unity local avoidance in user created world -