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. .NET (Core and Framework)
  4. Error eith InteropService.COMException

Error eith InteropService.COMException

Scheduled Pinned Locked Moved .NET (Core and Framework)
helpcsharpdebugging
6 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.
  • C Offline
    C Offline
    chillspider
    wrote on last edited by
    #1

    I wrote a service that use VB6 MSCOMM32.OCX for serial communication. I works perfectly on my development machine which has both .NET studio and VB6 installed. But when I bring it over to a computer w/o VB6 installed it doesn't work (i registered MSCOMM32.OCX). I got the following error: System.InteropService.COMException from the service. The odd thing is that the service monitor tool which is a winform application, which also use MSCOMM32.OCX but has a wrapper class that generated by winform, works perfectly as well. the Error when I debug it says: Class is not licensed to use Please help. Thanks

    S M 2 Replies Last reply
    0
    • C chillspider

      I wrote a service that use VB6 MSCOMM32.OCX for serial communication. I works perfectly on my development machine which has both .NET studio and VB6 installed. But when I bring it over to a computer w/o VB6 installed it doesn't work (i registered MSCOMM32.OCX). I got the following error: System.InteropService.COMException from the service. The odd thing is that the service monitor tool which is a winform application, which also use MSCOMM32.OCX but has a wrapper class that generated by winform, works perfectly as well. the Error when I debug it says: Class is not licensed to use Please help. Thanks

      S Offline
      S Offline
      Simon Gregory
      wrote on last edited by
      #2

      What was the COM exception?

      C 1 Reply Last reply
      0
      • S Simon Gregory

        What was the COM exception?

        C Offline
        C Offline
        chillspider
        wrote on last edited by
        #3

        The exception was thrown was System.InteropService.COMException, the error message was : class is not licensed for use. Other than that, it doesn't have any other error. Please note that it works fine on the machine that has both .NET Studio and VB6 installed...but not others. Jimmy

        S 1 Reply Last reply
        0
        • C chillspider

          The exception was thrown was System.InteropService.COMException, the error message was : class is not licensed for use. Other than that, it doesn't have any other error. Please note that it works fine on the machine that has both .NET Studio and VB6 installed...but not others. Jimmy

          S Offline
          S Offline
          Simon Gregory
          wrote on last edited by
          #4

          Is it the lciense file for the OCX. I think the corresponding OCA has something to do with this but what do I know...

          C 1 Reply Last reply
          0
          • S Simon Gregory

            Is it the lciense file for the OCX. I think the corresponding OCA has something to do with this but what do I know...

            C Offline
            C Offline
            chillspider
            wrote on last edited by
            #5

            I copied the OCA file with it as well...but nothing works. as I mention, this is odd since the winform version works fine, but the service one doesn't.

            1 Reply Last reply
            0
            • C chillspider

              I wrote a service that use VB6 MSCOMM32.OCX for serial communication. I works perfectly on my development machine which has both .NET studio and VB6 installed. But when I bring it over to a computer w/o VB6 installed it doesn't work (i registered MSCOMM32.OCX). I got the following error: System.InteropService.COMException from the service. The odd thing is that the service monitor tool which is a winform application, which also use MSCOMM32.OCX but has a wrapper class that generated by winform, works perfectly as well. the Error when I debug it says: Class is not licensed to use Please help. Thanks

              M Offline
              M Offline
              MadsJ
              wrote on last edited by
              #6

              We are having the same problem and have talked with MS. It seems like MSCOMM32.OCX requires some kind of certificate before it can be used, and that certificate is installed when you install VB6. Our way around it is this: http://msdn.microsoft.com/msdnmag/issues/02/10/NETSerialComm/ Hope this helps, Mads

              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