Q: Possible to change ASP.NET's page compilation behavior?

J

Jiho Han

I was wondering whether it was possible to change the default ASP.NET
compilation behavior.
I know that there is <compilation> element in the config where you can
specify quite a few things including the compiler options, assemblies to
link, etc. However, I can't seem to find a way to have the compiler add/use
certain path to locate the dlls.

I tried setting compilerOptions attribute of the <compiler> element
(compilerOptions="/lib:c:\sompath") but that doesn't seem to work either.
Having the <probing> element specify where to find assemblies at runtime is
very nice. I wish there was a similar facility for specifying locations to
search for during compile time.

Does anyone know of a way to do this?
Thanks
 
J

Jiho Han

Hi Natty,

Thanks for the response. However, I already looked into the <assemblies>
element and I don't think it's going to work.
To satisfy your curiosity, this is what I am trying to do.

In my ASP.NET application, I have a bunch of subfolders that basically
represent different modules/add-ons. These folders are underneath a common
folder that contains resources and assemblies that they all use. And
finally the common folder is located in the application root. Normally, all
assemblies will be located in the application bin folder. I am trying,
however, to place assemblies in different place under the application root.
My common assemblies will be in the common folder's bin folder and each
module specific assemblies under their own bin folder.

I can achieve this by using <probing> element but the <probing> element only
works during runtime. At compile time, ASP.NET looks only in the
application bin folder for its references, namely the dlls that contain
codebehind classes for the pages. <assemblies> doesn't seem like it's going
to work because you can only specify the assembly name or *, which would
look under application bin folder anyway.

So if you know of a way to achieve what I am trying to, please don't
hesistate to let me know.
Thanks much.

Jiho
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top