Dear All, I am using the bellow lines
mshtml.HTMLHeadElementClass elDynHead = null;
foreach (IHTMLElement elcol in (IHTMLElementCollection)document.getElementsByTagName("HEAD"))
{
if (elcol.ToString() == "mshtml.HTMLHeadElementClass")
{
elDynHead = (mshtml.HTMLHeadElementClass)elcol;
}
}
it works in Develpement system, but not in the client system it throws the following error
Error :: System.InvalidCastException: Unable to cast COM object of type 'System.__ComObject' to class type 'mshtml.HTMLHeadElementClass'. COM components that enter the CLR and do not support IProvideClassInfo or that do not have any interop assembly registered will be wrapped in the __ComObject type. Instances of this type cannot be cast to any other class; however they can be cast to interfaces as long as the underlying COM component supports QueryInterface calls for the IID of the interface.
at PAW_URL.clsURLMON.browser_DocumentComplete(Object pDisp, Object& URL)
so i think i have to Register mshtml in GAC. But i dont know how to do it. can some one help me how to Register the mshtml.dll in to GAC.(urgent please) thanks in Adavnce