Last post Sep 11, 2017 11:22 PM by bruce (sqlwork.com)
Sep 11, 2017 05:18 PM|terryclancy1|LINK
My ASP.Net MVC 5 Solution uses several third path components and requires both version 184.108.40.206 and 220.127.116.11 of Lucene.net.dll.
Because of this I am trying to use the Reference / Extern Alias property to allow me to explicitly reference the 18.104.22.168 version of the DLL to avoid Error CS0433 (I will
post separately about that error looking for any other solutions to that issue, in this post I will focus on getting Reference / Extern Alias working ).
For detail on how to use Extern Aliases see Post 5 by Lloyd at https://stackoverflow.com/questions/14708633/using-two-different-versions-of-the-same-dll-in-an-asp-site-using-two-sdks
This approach works fine for c# *.cs files but I get an error when trying to do it on a Razor *.cshtml page.
Specifically, the line:
Results in error “Invalid Expression term ‘Extern’”
Is this a limitation of Razor or is there a way around this problem ?
Any other comments or suggestions would also be appreciated.
Sep 11, 2017 11:22 PM|bruce (sqlwork.com)|LINK
razor does not support extern. you should wrap the externs with class module that razor uses.