-----------------------------------------------------------
New Message on BDOTNET
-----------------------------------------------------------
From: Sitaraman
Message 2 in Discussion
Hi Senthil You are facing this problem coz, when the page is loaded, it is not able
to find the Type 'gac.GACTEST' . Do understand that installing the Assembly in GAC
will not automatically make the ASP.Net runtime look for it. This is coz there might
be hundreds of assemblies in the GAC and it does not make sene to unnecessarily
reference all these assemblies by default. So what are the assemblies that are
referenced when the page is loaded? This is determined by the <assemblies> tag of the
machine.config. If you look at the System.Web Section of the machine.config inside
your <Framework>\Config dir, it will be like this <compilation debug="false"
explicit="true" defaultLanguage="vb">
<compilers>
<compiler language="c#;cs;csharp" extension=".cs"
type="Microsoft.CSharp.CSharpCodeProvider, System, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="1"/>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb"
type="Microsoft.VisualBasic.VBCodeProvider, System, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
<compiler language="js;jscript;javascript" extension=".js"
type="Microsoft.JScript.JScriptCodeProvider, Microsoft.JScript, Version=7.0.5000.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
<compiler language="VJ#;VJS;VJSharp" extension=".jsl"
type="Microsoft.VJSharp.VJSharpCodeProvider, VJSharpCodeProvider, Version=7.0.5000.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/></compilers>
<assemblies>
<add assembly="mscorlib"/>
<add assembly="System, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089"/>
<add assembly="System.Web, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"/>
<add assembly="System.Data, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089"/>
<add assembly="System.Web.Services, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"/>
<add assembly="System.Xml, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089"/>
<add assembly="System.Drawing, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"/>
<add assembly="System.EnterpriseServices, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"/>
<add assembly="System.Web.Mobile, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"/>
<add assembly="*"/>
</assemblies> So for all ur aspx pages the assemblies mentioned above only will
be loaded from the GAC. In addition to those, note that there is a <add
assembly="*"/> . This means that all the assemblies in your app bin will also be
loaded. So how do you reference your 'gac.GACTEST' and make ur code work . It is
quite simple. one way is to add the reference info in the machine.config. but that
is not recommended. Instead, Add the section below in your application web.config
file and it will perfectly work <compilation defaultLanguage="vb" debug="true">
<assemblies>
<add assembly="AssemblyName, Version=1.0.1307.30518, Culture=neutral,
PublicKeyToken=79c07095715ced96, Custom=null"/>
</assemblies>
</compilation> Note : Items marked in "Bold Italic" need to be changed
according to your program. you can get the information bout the gac assembly name
ver, public key etc by using th command gacutil /ldl in the command prompt. Also your
web.config might already have the compilation section, in which case you can
overwrite it with this instead of adding it. You will then be able to run ur
application without any problem. Hope this helps regards, sr
-----------------------------------------------------------
To stop getting this e-mail, or change how often it arrives, go to your E-mail
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw
Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help
For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact
If you do not want to receive future e-mail from this MSN group, or if you received
this message by mistake, please click the "Remove" link below. On the pre-addressed
e-mail message that opens, simply click "Send". Your e-mail address will be deleted
from this group's mailing list.
mailto:[EMAIL PROTECTED]