0

I have DLL. I have to use DLL to make webmethod calls in my project. Unfortunately DLL is having internal interface. How can I access methods inside interface?

Paulo Mendonça
  • 635
  • 12
  • 28
priya
  • 9
  • 6

1 Answers1

0

You can access methods by reflection How do I use reflection to invoke a private method?

You cannot use interface (e.g. create classes implemeting the interface, cast to the interface) if it's internal in another assembly. If you can change the assembly you reference you can add InternalsVisibleToAttribute by adding this to the the assembly code you refrence

[assembly: InternalsVisibleTo("YourOtherAssembly")]
allnau
  • 323
  • 1
  • 5