c# - Application.EnableVisualStyles() not working -
i cann't make application apply windows visual styles. application.enablevisualstyles() in program.cs not changing renderwithvisualstyle property true.
[stathread] public static void main(string[] startargument) { application.enablevisualstyles(); application.setcompatibletextrenderingdefault(false); ..... }
interestingly if i'm debugging "enable visual studio hosting process", application.enablevisualstyles() works expected, renderwithvisualstyle goes true , styles applied. no styles without hosting process either debug or release mode. changing target framework v.2 v.3.5 makes nothing.
any ideas please, i'm stuck issue , googling 3 days no success.
many thanks
you need embed manifest xml file specifies new version of common controls dll should used. see the msdn article on visual styles more information on how this.
Comments
Post a Comment