Could not load file or assembly 'Microsoft.Office.Interop.Excel, Version=11.0.0.0
-
Hi Guys Need advises, On my develop PC i am able to generate Excel Reports. However once port to an server this Error Occur :Could not load file or assembly 'Microsoft.Office.Interop.Excel, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified. In my Development PC I have already add reference of the Excel object 11. How come when i port to server it can't be detected. I am using VS 2005 Need Help urgently Thanks A million
KaKaShi HaTaKe
Check The properties of dll you added and verify that Copy Local property is set to true.If not make it true and rebuild your Application.
Shujaat
-
HatakeKaKaShi wrote:
How come when i port to server it can't be detected. I am using VS 2005
maybe. you doesn't add this dll in your setup... So, what you can do now is that you upload this dll on the server and register it or adding it into GAC. or..install Microsoft Office on the server :)
Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net) "Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
But 'Microsoft.Office.Interop.Excel does not have dll right cos i can't seem to find it. where to get the dll of this and how to adding in to GAC? Need helps man Thanks A lot of million
KaKaShi HaTaKe
-
But 'Microsoft.Office.Interop.Excel does not have dll right cos i can't seem to find it. where to get the dll of this and how to adding in to GAC? Need helps man Thanks A lot of million
KaKaShi HaTaKe
As Shujaat suggested, "Copy Local" might work but you need to re-package your setup file.. "Interop.Excel.dll" should be under bin\debug folder.
HatakeKaKaShi wrote:
how to adding in to GAC
sorry. you don't need to add it in to GAC as this dll is COM..
Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net) "Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
-
Hi Guys Need advises, On my develop PC i am able to generate Excel Reports. However once port to an server this Error Occur :Could not load file or assembly 'Microsoft.Office.Interop.Excel, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified. In my Development PC I have already add reference of the Excel object 11. How come when i port to server it can't be detected. I am using VS 2005 Need Help urgently Thanks A million
KaKaShi HaTaKe
Hi, I have recently encountered the same problem on my PC, my local IIS server would work with OWC11 but the remote server would not. What ended up being the case is that the interop DLL was not installed on the remote server's GAC (global assembly cache). One way to check and see if the Remote server has the correct interop in its GAC is to go onto your remote server, go into Start->Run (it has to be run because Explorer can't browse to it) and type in "C:\windows\assembly\gac". An Explorer window should appear, and if a folder named "Microsoft.Office.Interop.Excel" exists on the remote server, then my suggestion won't help. But, if this folder is missing, you can copy that directory from your local GAC to the Remote server's GAC. A direct copy of the folder from PC to PC works; I had to do this when I was installing my application on my remote server. I hope this helps, Mitch -- modified at 0:51 Friday 16th November, 2007
-
Check The properties of dll you added and verify that Copy Local property is set to true.If not make it true and rebuild your Application.
Shujaat
However , i can't seem to set the copy local property to true... May i know how to set it Thanks
KaKaShi HaTaKe
-
However , i can't seem to set the copy local property to true... May i know how to set it Thanks
KaKaShi HaTaKe
Go to Solution Explorer There must be node with name References under this node you will get all the dlls you have added in your project now select the required dll right Click on it and go to properties now You would see the Copy Local property set it to true.
Shujaat
-
Hi, I have recently encountered the same problem on my PC, my local IIS server would work with OWC11 but the remote server would not. What ended up being the case is that the interop DLL was not installed on the remote server's GAC (global assembly cache). One way to check and see if the Remote server has the correct interop in its GAC is to go onto your remote server, go into Start->Run (it has to be run because Explorer can't browse to it) and type in "C:\windows\assembly\gac". An Explorer window should appear, and if a folder named "Microsoft.Office.Interop.Excel" exists on the remote server, then my suggestion won't help. But, if this folder is missing, you can copy that directory from your local GAC to the Remote server's GAC. A direct copy of the folder from PC to PC works; I had to do this when I was installing my application on my remote server. I hope this helps, Mitch -- modified at 0:51 Friday 16th November, 2007
Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80040154. Hi i did what you mention but after that i gotten this error . May i know what's the error Thanks A Million
KaKaShi HaTaKe
-
Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80040154. Hi i did what you mention but after that i gotten this error . May i know what's the error Thanks A Million
KaKaShi HaTaKe
I had never experienced that error myself. One suggestion that I will give to you to try and run "regsvr32 dllname.dll" on the DLL that you are using to interface with Excel (this is not the interop DLL that you just copied across). When I did this on my server, I had to run "regsvr32 OWC11.DLL" to get it to work, however, the DLL that you have to register might be under a different name. I hope this helps, Mitch
-
I had never experienced that error myself. One suggestion that I will give to you to try and run "regsvr32 dllname.dll" on the DLL that you are using to interface with Excel (this is not the interop DLL that you just copied across). When I did this on my server, I had to run "regsvr32 OWC11.DLL" to get it to work, however, the DLL that you have to register might be under a different name. I hope this helps, Mitch
What do u mean by run "regsvr32 dllname.dll" on the DLL? How to do that Please guide Thanks a million
KaKaShi HaTaKe
-
What do u mean by run "regsvr32 dllname.dll" on the DLL? How to do that Please guide Thanks a million
KaKaShi HaTaKe
Hi, Is the COM component that you added a reference to in your VS .Net project on the remote server as well? If it isn't you will also have to install that COM component on the server. If it is on the server, open up Command Prompt on the server, and change the directory to the location of that COM DLL. Then, in the command prompt type in "regsvr32 COMDLLNAME.dll" and press enter. You should get a messagebox saying that the DLL was registered correctly. Press OK, and try your ASP project again. Eg, When I did this on my server, I had used the OWC11.dll as the reference to the charting controls. So, once I had located the DLL on the remote server, I had to manually register the COM dll using "regsvr32 OWC11.dll" in command prompt. I hope this helps, Mitch
-
Hi, Is the COM component that you added a reference to in your VS .Net project on the remote server as well? If it isn't you will also have to install that COM component on the server. If it is on the server, open up Command Prompt on the server, and change the directory to the location of that COM DLL. Then, in the command prompt type in "regsvr32 COMDLLNAME.dll" and press enter. You should get a messagebox saying that the DLL was registered correctly. Press OK, and try your ASP project again. Eg, When I did this on my server, I had used the OWC11.dll as the reference to the charting controls. So, once I had located the DLL on the remote server, I had to manually register the COM dll using "regsvr32 OWC11.dll" in command prompt. I hope this helps, Mitch
I used the above method in the end the message was Entry point Not found Any solutions?
KaKaShi HaTaKe