change bin location for wcf service

Posted by Zivtir under WCF on 6/13/2011 | Points: 10 | Views : 2322 | Status : [Member] | Replies : 2
Hi

I am hosting WCF service in IIS which use assemblies that located under the BIN sub directory.

if I want to locate these assemblies in different location such as: c:\programfiles\myApp\bin

how can i manage it? the tag: '<probing privatePath=...' > related only to sub directory of the virtual directory.

thanks




Responses

Posted by: Robin_ahuja2008 on: 6/15/2011 [Member] Starter | Points: 25

Up
0
Down
You can set aspNetCompatibilityEnabled to "true"
using <system.serviceModel> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" /> </system.serviceModel> and you can use Server.Mappath to get the physical directory. e.g. String rootPath = Server.MapPath("~");
For details: http://msdn.microsoft.com/en-us/library/ms178116.aspx
Hope this helps...

Regards,
Robin Ahuja

Zivtir, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Zivtir on: 6/21/2011 [Member] Starter | Points: 25

Up
0
Down
maybe I wasnt clear, when my SVC hosted in IIS I want to locate its BIN under c:\programfiles\myApp\bin and not under the BIN where the virtual directory is.

Zivtir, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response