Results 1 to 14 of 14

Thread: Mscomm32.ocx on VB.NET

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2003
    Posts
    784

    Mscomm32.ocx on VB.NET

    Dear The Expert,

    I am trying to use vb6's mscomm control (mscomm32.ocx) on vb.net .. when drag to form, I got the following error message:
    "You do not have a license to use this ActiveX control" ..

    am I missing something?

    Please advise . thanks a lot in advance

    Regards
    Winanjaya

  2. #2
    type Woss is new Grumpy; wossname's Avatar
    Join Date
    Aug 2002
    Location
    #!/bin/bash
    Posts
    5,682
    Yes you are.

    The easiest thing to do would be to install VB6 on your .net machine.
    I don't live here any more.

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Nov 2003
    Posts
    784
    my vb.net application is commercial application, does it also will happen on target PC? , it's not funny if it also required to install vb6 on target PC.. any idea ?

    Thanks

    Winanjaya

  4. #4
    New Member
    Join Date
    Mar 2004
    Posts
    1

    MSComm32 Registry

    You do not need to install VB 6 to customer PC. When you use any com object , VB.NET adds the object to your project and also install to target machine.

    To use the object , you need register VB 6 controls to your machine. You will find a registry file in your VB.NET CD1
    (folder name is "...:\Extras\VB6 Controls\vb6controls.reg" )
    Double click the file and add it to your registry.

    That's all

    Good Luck

  5. #5
    Fanatic Member
    Join Date
    Jul 2003
    Posts
    830
    I am getting this error on my target machine. What could possibly be wrong if VB.NET adds the object to your project and also install to target machine? Apparently, it did not.

    Thanks!

  6. #6
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Will this help :
    Attached Files Attached Files

  7. #7
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    any OCX needs to be registered on the machine it is installed to (this is one of the major downfalls of COM that no longer exists in .NET)

    problem is if you use any COM stuff, even in a .NET app, it still needs to be registered using regsvr32

  8. #8
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    or use : Regasm.exe

  9. #9
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    Originally posted by Pirate
    or use : Regasm.exe
    isnt that for .net assemblies?

  10. #10
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Originally posted by kleinma
    isnt that for .net assemblies?
    which use COMs , if I remember correctly ... . If it's the tool that make callable wrapper for the COM and needs no registeration later . Correct me if I'm wrong .

  11. #11
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    Originally posted by Pirate
    which use COMs , if I remember correctly ... . If it's the tool that make callable wrapper for the COM and needs no registeration later . Correct me if I'm wrong .
    ok I will

    I think what it actually is, is the opposite. It wraps a .net assembly so it can be called from COM

    http://msdn.microsoft.com/library/de...lregasmexe.asp

  12. #12
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    Originally posted by kleinma
    ok I will

    I think what it actually is, is the opposite. It wraps a .net assembly so it can be called from COM

    http://msdn.microsoft.com/library/de...lregasmexe.asp
    Then I must have confused it with another tool . I think I was talking about Tlbimp.exe , if that helps .

  13. #13
    Fanatic Member
    Join Date
    Jul 2003
    Posts
    830
    Thanks...but how do I do this on the target machine?

    Will the below work for the problem we are talking about for a target machine or is this only good for the design time error?

    <<
    To use the object , you need register VB 6 controls to your machine. You will find a registry file in your VB.NET CD1
    (folder name is "...:\Extras\VB6 Controls\vb6controls.reg" )
    Double click the file and add it to your registry.
    >>
    Last edited by birthjay; Dec 1st, 2004 at 01:21 PM.

  14. #14
    Fanatic Member
    Join Date
    Jul 2003
    Posts
    830
    Well....running the VB6CONTROLS.REG file on the target seemed to fix the problem. It may not be the final solution, but worked for now.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width