You are not logged in.

Dear visitor, welcome to Jabaco - Community. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

KrossBeaux

Beginner

  • "KrossBeaux" is male
  • "KrossBeaux" started this thread

Posts: 6

Date of registration: Apr 29th 2009

Location: Georgetown, Guyana

Occupation: Firefighter

Hobbies: Programming, gaming, reading, writing

  • Send private message

1

Thursday, April 30th 2009, 6:08pm

A way to convert vb ocx a dll files to Jabaco

I'm new here, but it would be great if there was a way to convert existing vbdlls and ocx files so that the work with Jabaco. Great implementation of basic to bytecode btw. Loving Jabaco. :thumbup:

A1880

Intermediate

  • "A1880" is male

Posts: 500

Date of registration: Jan 1st 2009

Location: Hanover, Germany

Occupation: Software Engineer

Hobbies: Hilbert Curves

  • Send private message

2

Thursday, April 30th 2009, 6:51pm

Hi,
are you talking about ActiveX?
This feature has been asked for several times.

Happy experimenting!

A1880

This post has been edited 1 times, last edit by "A1880" (Jun 9th 2009, 9:05am)


  • "StefanSchnell" is male

Posts: 102

Date of registration: Mar 13th 2009

Location: Oberirsen - Germany

Occupation: Senior Software Engineer

Hobbies: Programming aund Photography

  • Send private message

3

Thursday, April 30th 2009, 6:55pm

Hello KrossBeaux,
welcome to Jabaco.
Do you have a simple example to test? I never programmed a DLL or OCX in Visual Basic.
Cheers
Stefan
Visit my personal or commercial site
If you have questions or suggestions, write me an eMail or
meet me here

KrossBeaux

Beginner

  • "KrossBeaux" is male
  • "KrossBeaux" started this thread

Posts: 6

Date of registration: Apr 29th 2009

Location: Georgetown, Guyana

Occupation: Firefighter

Hobbies: Programming, gaming, reading, writing

  • Send private message

4

Monday, June 8th 2009, 5:49pm

Yup was talking about activex, btw your link is invalid. Thnks for the help :)

StevenP

Beginner

Posts: 7

Date of registration: Jan 9th 2009

  • Send private message

5

Tuesday, June 9th 2009, 6:05am

ActiveX is COM with the IDispatch interface. COM is basically a standard Windows DLL or EXE with exported functions that provide access to an interface called IUnknown (btw, an OCX is still just a DLL). Using IUnknown the host application can early bind to various interfaces provided by the COM or ActiveX component. When you bind to an interface you really are intantiating a class and reference the object's functions using function pointers. VB always did a wonderful job hiding all this complexity for us. ActiveX extends COM by providing the IDispatch interface which enables COM to be used in late binding environments such VBScript (VB 6 can do both) where early binding doesn't work since they don't work with function pointers (late binding is very slow). Without getting too deep (it is a large topic) writing ActiveX components in JAVA is not possible since the ActiveX must be a standard cdecl DLL which JAVA can not create. Accessing ActiveX in JAVA is possible using JNI but still difficult (requires a lot of work). Low level COM and ActiveX is one of the most complex topics in windows development.

The fact is, it is better to look for premade JAVA beans to use in Jacabo than rely on existing ActiveX components. There are a lot out there that people might want to write a Jacabo wrapper around.

OlimilO

Intermediate

  • "OlimilO" is male

Posts: 277

Date of registration: Jan 18th 2009

Location: Germany

Occupation: software engineer

  • Send private message

6

Tuesday, June 9th 2009, 7:02am

hi,

Quoted

writing ActiveX components in JAVA is not possible

If we talk about ActiveX we should distinguish between writing and using it.
* writing:
we are glad not to be in JAVA, so writing ActiveX-dlls with Jabaco could be possible to implement if you bypass the Jabaco Compiler and do it with a new "COM"-compiler.
But who wants to implement this feature in Jabaco? one could use Microsoft VB if he wants to write ActiveXdlls
* using:
I must admit i have not tried this before in Jabaco. But look at this:

How to use ActiveX-controls with Jabaco


btw:

Quoted

since the ActiveX must be a standard cdecl DLL
It is possible to edit your post. Read carefully what you have written and edit it: "standard call DLL"
I will delete this hint afterwards OK?

greetings
OlimilO

This post has been edited 1 times, last edit by "OlimilO" (Jun 9th 2009, 7:13am)


A1880

Intermediate

  • "A1880" is male

Posts: 500

Date of registration: Jan 1st 2009

Location: Hanover, Germany

Occupation: Software Engineer

Hobbies: Hilbert Curves

  • Send private message

7

Tuesday, June 9th 2009, 9:02am

Hi,
"cdecl" (or "_cdecl") refers to a calling convention in Microsoft C/C++. See here

Best regards

A1880

StevenP

Beginner

Posts: 7

Date of registration: Jan 9th 2009

  • Send private message

8

Tuesday, June 9th 2009, 5:55pm



Quoted

since the ActiveX must be a standard cdecl DLL
It is possible to edit your post. Read carefully what you have written and edit it: "standard call DLL"
I will delete this hint afterwards OK?

OlimilO
You are correct, OlimilO, COM is written in std call. I got those swapped in my head. VB requires a hack like this to use cdecl (http://pscode.com/vb/scripts/ShowCode.as…=49776&lngWId=1) I have studied COM and ActiveX extensively from writing them in C to C++ without a helper framework like MFC or ATL all the way to using ATL in C++. It was quite a learning experience.

The importance of the type of DLL, in this case, refers to the order in which the parameters are pushed on to the stack and who is responsible for clearing the values after words.

The primary purpose of my post was to explain that COM and ActiveX is not just standard VB code but something far more complex. There are those, like you, that understand that but most VB programmers don't.

Also, the original poster did state he wanted to convert existing "vb" dlls and OCX's:

Quoted

A way to convert vb ocx a dll files to Jabaco

I'm new here, but it would be great if there was a way to convert existing vbdlls and ocx files so that the work with Jabaco. Great implementation of basic to bytecode btw. Loving Jabaco

This post has been edited 2 times, last edit by "StevenP" (Jun 9th 2009, 6:04pm)


Manuel

Administrator

  • "Manuel" is male

Posts: 256

Date of registration: Jul 16th 2008

Location: Erlangen, Germany

Occupation: Software Developer

Hobbies: Jabaco, game theory, text-mining

  • Send private message

9

Thursday, June 25th 2009, 11:31pm

This could be an approach for a generic container-control: http://extentech.sys-con.com/node/48177

Rate this thread
WoltLab Burning Board