Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. DLLs required to use GetObject() method in VB.Net

DLLs required to use GetObject() method in VB.Net

Scheduled Pinned Locked Moved Visual Basic
csharpcomvisual-studioquestion
8 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Raheem MA
    wrote on last edited by
    #1

    Hello, We have a VB.Net program that uses GetObject() method. While executing the program, it gives the following exception. "Unhandled Exception: System.Exception: Cannot create ActiveX component. at Microsoft.VisualBasic.Interaction.GetObject(String PathName, String Class)" The same program is executing successfully in our production environment but not in one of the development environment. We came to know that the program referring to STDOLE.DLL which is not there on the development machine where the program fails. Even if we copy the same dll on that machine, it is not working. How can we install Primary Interop Assemblies seperately? we do not want to install Visual studio.net. Please let me know what are all the dlls required to use GETOBJECT() method in VB.Net program? Thank you in advance, :) Raheem MA :)

    T 1 Reply Last reply
    0
    • R Raheem MA

      Hello, We have a VB.Net program that uses GetObject() method. While executing the program, it gives the following exception. "Unhandled Exception: System.Exception: Cannot create ActiveX component. at Microsoft.VisualBasic.Interaction.GetObject(String PathName, String Class)" The same program is executing successfully in our production environment but not in one of the development environment. We came to know that the program referring to STDOLE.DLL which is not there on the development machine where the program fails. Even if we copy the same dll on that machine, it is not working. How can we install Primary Interop Assemblies seperately? we do not want to install Visual studio.net. Please let me know what are all the dlls required to use GETOBJECT() method in VB.Net program? Thank you in advance, :) Raheem MA :)

      T Offline
      T Offline
      tosch
      wrote on last edited by
      #2

      Are you sure the ActiveX component is correctly registered? The error you get is not an error of the GetObject function but that your ActiveX component is not registered correctly. Try to registed the component by executing 'regsvr32 x:\path\myactivex.dll'.

      Tosch

      R 1 Reply Last reply
      0
      • T tosch

        Are you sure the ActiveX component is correctly registered? The error you get is not an error of the GetObject function but that your ActiveX component is not registered correctly. Try to registed the component by executing 'regsvr32 x:\path\myactivex.dll'.

        Tosch

        R Offline
        R Offline
        Raheem MA
        wrote on last edited by
        #3

        Thank you for quick reply, We do not have STDOLE.DLL on our machine. So it cannot be registered right? What is required to install on the machine to get this dll? once again reminding you we do not want to install Visual studio.Net. Thank you, Raheem MA

        H 1 Reply Last reply
        0
        • R Raheem MA

          Thank you for quick reply, We do not have STDOLE.DLL on our machine. So it cannot be registered right? What is required to install on the machine to get this dll? once again reminding you we do not want to install Visual studio.Net. Thank you, Raheem MA

          H Offline
          H Offline
          helelark123
          wrote on last edited by
          #4

          You have to make a setup project from the computer that VS.net is installed on. After that you have to run the setup installation file on the required machine.

          Shay Noy

          R 1 Reply Last reply
          0
          • H helelark123

            You have to make a setup project from the computer that VS.net is installed on. After that you have to run the setup installation file on the required machine.

            Shay Noy

            R Offline
            R Offline
            Raheem MA
            wrote on last edited by
            #5

            I think this answer is not related to my question. I read somewhere that STDOLE.DLL comes with Visual Studio.Net. Are there any alternatives to get this DLL installed without Visual Studio.Net? Thanks.

            H 1 Reply Last reply
            0
            • R Raheem MA

              I think this answer is not related to my question. I read somewhere that STDOLE.DLL comes with Visual Studio.Net. Are there any alternatives to get this DLL installed without Visual Studio.Net? Thanks.

              H Offline
              H Offline
              helelark123
              wrote on last edited by
              #6

              I would like to understand: Does the program, written on the machine which VS.net is installed on, run succesfully? If yes, you have to create a new setup project including all the required files (also STDOLE.dll) and then run it in the relevant computer. Do I understood correctly what you need?

              Shay Noy

              R 1 Reply Last reply
              0
              • H helelark123

                I would like to understand: Does the program, written on the machine which VS.net is installed on, run succesfully? If yes, you have to create a new setup project including all the required files (also STDOLE.dll) and then run it in the relevant computer. Do I understood correctly what you need?

                Shay Noy

                R Offline
                R Offline
                Raheem MA
                wrote on last edited by
                #7

                yes, our program is a console application which is called from formscape reports. we have copied only exe of the program in the production and running successfully. On the production system, we have primary Interop Assemblies folder at the following path: C:\Program Files\Microsoft.NET\Primary Interop Assemblies Following are the contents of the folder: 1. adodb.dll 2. Microsoft.mshtml.dll 3. Microsoft.stdformat.dll 4. msdatasrc.dll 5. MSDDSLMP.DLL 6. MSDDSP.DLL 7. stdole.dll - This is reffered in our program. We could not find this folder on development machine. That may be the reason we are getting the exception saying 'Cannot create ActiveX .....". How can we install these dlls ? Please shed some light in this scenario. Thank you in advance Raheem MA

                H 1 Reply Last reply
                0
                • R Raheem MA

                  yes, our program is a console application which is called from formscape reports. we have copied only exe of the program in the production and running successfully. On the production system, we have primary Interop Assemblies folder at the following path: C:\Program Files\Microsoft.NET\Primary Interop Assemblies Following are the contents of the folder: 1. adodb.dll 2. Microsoft.mshtml.dll 3. Microsoft.stdformat.dll 4. msdatasrc.dll 5. MSDDSLMP.DLL 6. MSDDSP.DLL 7. stdole.dll - This is reffered in our program. We could not find this folder on development machine. That may be the reason we are getting the exception saying 'Cannot create ActiveX .....". How can we install these dlls ? Please shed some light in this scenario. Thank you in advance Raheem MA

                  H Offline
                  H Offline
                  helelark123
                  wrote on last edited by
                  #8

                  As I told you before, you have to create a setup project. http://visualbasic.about.com/od/usingvbnet/a/SetupProj01_2.htm[^] and also read PartII

                  Shay Noy

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups