* gnat ada DLL and VB
@ 2001-08-09 8:29 isaac buchwald
2001-08-09 10:01 ` Pascal Obry
2001-08-13 14:50 ` David Botton
0 siblings, 2 replies; 16+ messages in thread
From: isaac buchwald @ 2001-08-09 8:29 UTC (permalink / raw)
Does anybody tryed to build a simple dll in gnat ada (v 3.13p) that
was
able to reference it in a visual basic (v 6.0) project - and it was
working?
If there is such a mighty ada programmer , please share your demo
code
with the community.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-09 8:29 gnat ada DLL and VB isaac buchwald
@ 2001-08-09 10:01 ` Pascal Obry
2001-08-09 12:53 ` Ted Dennison
2001-08-13 14:50 ` David Botton
1 sibling, 1 reply; 16+ messages in thread
From: Pascal Obry @ 2001-08-09 10:01 UTC (permalink / raw)
"isaac buchwald" <isaac.buchwald@velenje.cx> writes:
> Does anybody tryed to build a simple dll in gnat ada (v 3.13p) that
> was
> able to reference it in a visual basic (v 6.0) project - and it was
> working?
>
It has been done, look at Adapower I think there is some demos there.
Pascal.
--
--|------------------------------------------------------
--| Pascal Obry Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--| http://perso.wanadoo.fr/pascal.obry
--|
--| "The best way to travel is by means of imagination"
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-09 10:01 ` Pascal Obry
@ 2001-08-09 12:53 ` Ted Dennison
2001-08-09 21:33 ` Pascal Obry
0 siblings, 1 reply; 16+ messages in thread
From: Ted Dennison @ 2001-08-09 12:53 UTC (permalink / raw)
In article <uhevhtuuh.fsf@wanadoo.fr>, Pascal Obry says...
>It has been done, look at Adapower I think there is some demos there.
Rats. I thought you were going to step up as a "mighty Ada programmer". :-)
---
T.E.D. homepage - http://www.telepath.com/dennison/Ted/TED.html
home email - mailto:dennison@telepath.com
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-09 12:53 ` Ted Dennison
@ 2001-08-09 21:33 ` Pascal Obry
2001-08-10 6:06 ` isaac buchwald
0 siblings, 1 reply; 16+ messages in thread
From: Pascal Obry @ 2001-08-09 21:33 UTC (permalink / raw)
Ted Dennison<dennison@telepath.com> writes:
> Rats. I thought you were going to step up as a "mighty Ada programmer". :-)
Of course I could :) But I don't have a lot of time at the moment. At least
I gave a pointer :)
Pascal.
--
--|------------------------------------------------------
--| Pascal Obry Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--| http://perso.wanadoo.fr/pascal.obry
--|
--| "The best way to travel is by means of imagination"
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-09 21:33 ` Pascal Obry
@ 2001-08-10 6:06 ` isaac buchwald
2001-08-10 21:31 ` Tony Gair
0 siblings, 1 reply; 16+ messages in thread
From: isaac buchwald @ 2001-08-10 6:06 UTC (permalink / raw)
Thanks to pascal , i have found the demo.
It is COM dll and it works fine.
But the dll doesn't work , the famous error
7 when reference the dll in vb. It seems that
nobody is able to solve it.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-10 6:06 ` isaac buchwald
@ 2001-08-10 21:31 ` Tony Gair
2001-08-11 16:35 ` isaac buchwald
0 siblings, 1 reply; 16+ messages in thread
From: Tony Gair @ 2001-08-10 21:31 UTC (permalink / raw)
Does anyone think there was a moral to this story.
Out of interest Isaac why VB?
"isaac buchwald" <isaac.buchwald@velenje.cx> wrote in message
news:ASKc7.1606$bl.80971@news.siol.net...
> Thanks to pascal , i have found the demo.
> It is COM dll and it works fine.
> But the dll doesn't work , the famous error
> 7 when reference the dll in vb. It seems that
> nobody is able to solve it.
>
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-10 21:31 ` Tony Gair
@ 2001-08-11 16:35 ` isaac buchwald
2001-08-12 22:12 ` R. Srinivasan
0 siblings, 1 reply; 16+ messages in thread
From: isaac buchwald @ 2001-08-11 16:35 UTC (permalink / raw)
It's elementary, dear Tony.
I can't convience some people to use ada , if a simple library
writen in it
can't be used in visual basic program.
"Tony Gair" <tonygair@nospammy.blueyonder.co.uk> wrote in message
news:ToYc7.12116$pv6.739796@news1.cableinet.net...
> Does anyone think there was a moral to this story.
> Out of interest Isaac why VB?
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-11 16:35 ` isaac buchwald
@ 2001-08-12 22:12 ` R. Srinivasan
0 siblings, 0 replies; 16+ messages in thread
From: R. Srinivasan @ 2001-08-12 22:12 UTC (permalink / raw)
i have an example where i have :
- lex generated lexical analyzer for Ada source code (originally in aflex
but rewritten for flex)
- Ada package that performs some other added services
in a DLL that I use in a VB gui program.
If you have not found any useful examples, i will be happy to supply this.
please drop me an e-mail if you would like this.
regards
srini
"isaac buchwald" <isaac.buchwald@velenje.cx> wrote in message
news:T9dd7.1659$bl.83327@news.siol.net...
> It's elementary, dear Tony.
> I can't convience some people to use ada , if a simple library
> writen in it
> can't be used in visual basic program.
>
> "Tony Gair" <tonygair@nospammy.blueyonder.co.uk> wrote in message
> news:ToYc7.12116$pv6.739796@news1.cableinet.net...
> > Does anyone think there was a moral to this story.
> > Out of interest Isaac why VB?
> >
>
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-09 8:29 gnat ada DLL and VB isaac buchwald
2001-08-09 10:01 ` Pascal Obry
@ 2001-08-13 14:50 ` David Botton
2001-08-13 18:42 ` isaac buchwald
2001-08-14 0:29 ` R. Srinivasan
1 sibling, 2 replies; 16+ messages in thread
From: David Botton @ 2001-08-13 14:50 UTC (permalink / raw)
To: comp.lang.ada; +Cc: isaac.buchwald
Why would any one write a DLL on windows to work with VB or for that matter
with any language? Particularly when there are excellent COM/DCOM tools that
make creating COM objects with Ada 95 easier then perhaps even VB itself :-)
Step 1 - Write IDL and compile with MIDL to a TypeLibrary (or use a GUI type
library creation tool)
Step 2 - Run CreateCOM on TLB file
Step 3 - Fill in the blanks :-)
DONE
DLL's these days are only being developed for use with inferior languages
like C/C++ where the average programmer is too lazy to write/use COM/DCOM
objects since their tools and/or skills are not as well developed on the
Windows platform.
http://www.adapower.com/gnatcom
David Botton
----- Original Message -----
From: "isaac buchwald" <isaac.buchwald@velenje.cx>
> Does anybody tryed to build a simple dll in gnat ada (v 3.13p)
that
> was
> able to reference it in a visual basic (v 6.0) project - and it was
> working?
>
> If there is such a mighty ada programmer , please share your demo
> code
> with the community.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-13 14:50 ` David Botton
@ 2001-08-13 18:42 ` isaac buchwald
2001-08-13 19:12 ` David Botton
2001-08-14 0:29 ` R. Srinivasan
1 sibling, 1 reply; 16+ messages in thread
From: isaac buchwald @ 2001-08-13 18:42 UTC (permalink / raw)
It seems that VB is really a sophisticated lang these day :-)
and for the lazyness i prefer it on the programmer's side, not on the
runtime side.
"David Botton" <David@Botton.com> wrote in message
news:mailman.997714164.3020.comp.lang.ada@ada.eu.org...
> Why would any one write a DLL on windows to work with VB or for that
matter
> with any language? Particularly when there are excellent COM/DCOM tools
that
> make creating COM objects with Ada 95 easier then perhaps even VB itself
:-)
>
> Step 1 - Write IDL and compile with MIDL to a TypeLibrary (or use a GUI
type
> library creation tool)
> Step 2 - Run CreateCOM on TLB file
> Step 3 - Fill in the blanks :-)
>
> DONE
>
> DLL's these days are only being developed for use with inferior languages
> like C/C++ where the average programmer is too lazy to write/use COM/DCOM
> objects since their tools and/or skills are not as well developed on the
> Windows platform.
>
> http://www.adapower.com/gnatcom
>
> David Botton
>
>
>
> ----- Original Message -----
> From: "isaac buchwald" <isaac.buchwald@velenje.cx>
>
>
> > Does anybody tryed to build a simple dll in gnat ada (v 3.13p)
> that
> > was
> > able to reference it in a visual basic (v 6.0) project - and it
was
> > working?
> >
> > If there is such a mighty ada programmer , please share your
demo
> > code
> > with the community.
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-13 18:42 ` isaac buchwald
@ 2001-08-13 19:12 ` David Botton
0 siblings, 0 replies; 16+ messages in thread
From: David Botton @ 2001-08-13 19:12 UTC (permalink / raw)
To: comp.lang.ada
VB is certainly very sophisticated in every way (even from its first
version) although its sophistication has lead it to be more specialized to
the user world and not as general purpose as Ada or C/C++.
A good programmer know's that laziness on now will mean long term
maintenance problems. No execuse for it. One of the key personal reasons I
started using Ada, it forces me to write code that works the first time (if
it compiles chances are it works....) and I can read later :-)
As for the runtime side, C/C++ is very lazy on the runtime side, just think
about all that bounds checking C/C++ does :-)
David Botton
----- Original Message -----
From: "isaac buchwald" <isaac.buchwald@velenje.cx>
> It seems that VB is really a sophisticated lang these day :-)
> and for the lazyness i prefer it on the programmer's side, not on the
> runtime side.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-13 14:50 ` David Botton
2001-08-13 18:42 ` isaac buchwald
@ 2001-08-14 0:29 ` R. Srinivasan
2001-08-14 17:17 ` isaac buchwald
2001-08-15 13:42 ` David Botton
1 sibling, 2 replies; 16+ messages in thread
From: R. Srinivasan @ 2001-08-14 0:29 UTC (permalink / raw)
Many of us -- well speaking for myself, COM/DCOM/DCOM+ etc. etc. are not the
easiest to understand. These are comprehensive technologies that addresses a
broad range of issues. Even with supposedly "friendly" environments (to each
other I mean) like VC++ and VB, both the development, troubleshooting is
quite challenging to put it mildly -- particularly when it comes to
interoperation between VB/VC++.
Afterall one of the central theme of VS.NET namely the "much touted" CLR is
a testament to the issues involved.
"David Botton" <David@Botton.com> wrote in message
news:mailman.997714164.3020.comp.lang.ada@ada.eu.org...
> Why would any one write a DLL on windows to work with VB or for that
matter
> with any language? Particularly when there are excellent COM/DCOM tools
that
> make creating COM objects with Ada 95 easier then perhaps even VB itself
:-)
>
> Step 1 - Write IDL and compile with MIDL to a TypeLibrary (or use a GUI
type
> library creation tool)
> Step 2 - Run CreateCOM on TLB file
> Step 3 - Fill in the blanks :-)
>
> DONE
>
> DLL's these days are only being developed for use with inferior languages
> like C/C++ where the average programmer is too lazy to write/use COM/DCOM
> objects since their tools and/or skills are not as well developed on the
> Windows platform.
>
> http://www.adapower.com/gnatcom
>
> David Botton
>
>
>
> ----- Original Message -----
> From: "isaac buchwald" <isaac.buchwald@velenje.cx>
>
>
> > Does anybody tryed to build a simple dll in gnat ada (v 3.13p)
> that
> > was
> > able to reference it in a visual basic (v 6.0) project - and it
was
> > working?
> >
> > If there is such a mighty ada programmer , please share your
demo
> > code
> > with the community.
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-14 0:29 ` R. Srinivasan
@ 2001-08-14 17:17 ` isaac buchwald
2001-08-15 13:53 ` David Botton
2001-08-15 13:42 ` David Botton
1 sibling, 1 reply; 16+ messages in thread
From: isaac buchwald @ 2001-08-14 17:17 UTC (permalink / raw)
but there is one more reason , why not to use it.
If i write a package in ada , i would like to use in a different
invironment
without much ado , and without a separate layer that brings in a new
peril of quer functioning.
"R. Srinivasan" <rajasrinivasan@home.com> wrote in message
news:7i_d7.276991$qc.33250428@news1.rdc1.va.home.com...
> Many of us -- well speaking for myself, COM/DCOM/DCOM+ etc. etc. are not
the
> easiest to understand. These are comprehensive technologies that addresses
a
> broad range of issues. Even with supposedly "friendly" environments (to
each
> other I mean) like VC++ and VB, both the development, troubleshooting is
> quite challenging to put it mildly -- particularly when it comes to
> interoperation between VB/VC++.
>
> Afterall one of the central theme of VS.NET namely the "much touted" CLR
is
> a testament to the issues involved.
>
>
> "David Botton" <David@Botton.com> wrote in message
> news:mailman.997714164.3020.comp.lang.ada@ada.eu.org...
> > Why would any one write a DLL on windows to work with VB or for that
> matter
> > with any language? Particularly when there are excellent COM/DCOM tools
> that
> > make creating COM objects with Ada 95 easier then perhaps even VB itself
> :-)
> >
> > Step 1 - Write IDL and compile with MIDL to a TypeLibrary (or use a GUI
> type
> > library creation tool)
> > Step 2 - Run CreateCOM on TLB file
> > Step 3 - Fill in the blanks :-)
> >
> > DONE
> >
> > DLL's these days are only being developed for use with inferior
languages
> > like C/C++ where the average programmer is too lazy to write/use
COM/DCOM
> > objects since their tools and/or skills are not as well developed on the
> > Windows platform.
> >
> > http://www.adapower.com/gnatcom
> >
> > David Botton
> >
> >
> >
> > ----- Original Message -----
> > From: "isaac buchwald" <isaac.buchwald@velenje.cx>
> >
> >
> > > Does anybody tryed to build a simple dll in gnat ada (v 3.13p)
> > that
> > > was
> > > able to reference it in a visual basic (v 6.0) project - and it
> was
> > > working?
> > >
> > > If there is such a mighty ada programmer , please share your
> demo
> > > code
> > > with the community.
> >
> >
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-14 0:29 ` R. Srinivasan
2001-08-14 17:17 ` isaac buchwald
@ 2001-08-15 13:42 ` David Botton
1 sibling, 0 replies; 16+ messages in thread
From: David Botton @ 2001-08-15 13:42 UTC (permalink / raw)
To: comp.lang.ada
Thanks to CreateCOM there is no need to understand COM. Just fill in the
blanks and your Ada code will be instantly usable to VB, Delphi, MSVC++ and
on the CLR easier then with a DLL.
For example in VB after creating your Ada COM object. Register the DLL by
typing:
regsvr32 /r NameOfYourCOMObject
then in VB choose the references Object menu option and pick your object.
Use the Ada code as you would any other VB object. If this was a DLL, you
would have to writing a binding to each method in VB as well.
In MSVC++, do:
#import "Path\NameOfYourCOMObject.dll"
the just start working
MyInterfacePtr ABC;
ABC.CreateInstance (__uuidof (MyObject));
etc.
On top of that, say you wanted to do a little remote computing :-) Don't try
this with your DLL.
Go to a remote machine, run the CreateCOM generate program
NameOfYourCOMObject-Remote.exe on a remote machine and then run the _exact
same_ client code on that machine an be accessing your object accross the
network.
David Botton
----- Original Message -----
From: "R. Srinivasan" <rajasrinivasan@home.com>
> Many of us -- well speaking for myself, COM/DCOM/DCOM+ etc. etc. are not
the
> easiest to understand. These are comprehensive technologies that addresses
a
> broad range of issues. Even with supposedly "friendly" environments (to
each
> other I mean) like VC++ and VB, both the development, troubleshooting is
> quite challenging to put it mildly -- particularly when it comes to
> interoperation between VB/VC++.
>
> Afterall one of the central theme of VS.NET namely the "much touted" CLR
is
> a testament to the issues involved.
>
>
> "David Botton" <David@Botton.com> wrote in message
> news:mailman.997714164.3020.comp.lang.ada@ada.eu.org...
> > Why would any one write a DLL on windows to work with VB or for that
> matter
> > with any language? Particularly when there are excellent COM/DCOM tools
> that
> > make creating COM objects with Ada 95 easier then perhaps even VB itself
> :-)
> >
> > Step 1 - Write IDL and compile with MIDL to a TypeLibrary (or use a GUI
> type
> > library creation tool)
> > Step 2 - Run CreateCOM on TLB file
> > Step 3 - Fill in the blanks :-)
> >
> > DONE
> >
> > DLL's these days are only being developed for use with inferior
languages
> > like C/C++ where the average programmer is too lazy to write/use
COM/DCOM
> > objects since their tools and/or skills are not as well developed on the
> > Windows platform.
> >
> > http://www.adapower.com/gnatcom
> >
> > David Botton
> >
> >
> >
> > ----- Original Message -----
> > From: "isaac buchwald" <isaac.buchwald@velenje.cx>
> >
> >
> > > Does anybody tryed to build a simple dll in gnat ada (v 3.13p)
> > that
> > > was
> > > able to reference it in a visual basic (v 6.0) project - and it
> was
> > > working?
> > >
> > > If there is such a mighty ada programmer , please share your
> demo
> > > code
> > > with the community.
> >
> >
>
>
> _______________________________________________
> comp.lang.ada mailing list
> comp.lang.ada@ada.eu.org
> http://ada.eu.org/mailman/listinfo/comp.lang.ada
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-14 17:17 ` isaac buchwald
@ 2001-08-15 13:53 ` David Botton
2001-08-15 16:32 ` isaac buchwald
0 siblings, 1 reply; 16+ messages in thread
From: David Botton @ 2001-08-15 13:53 UTC (permalink / raw)
To: comp.lang.ada
The best way to create portable libraries in general is to abstract the OS
interface to the Ada code.
When you are writing a COM object you don't have to use ADO or any COM
objects with in your Ada code.
BTW, there is no seperate layer in COM itself when used inproc (DLL base COM
object).
As for layers in ADO (since you mentioned it), it depends on how you
connect.
ADO can do ADO/OLEDB -> ODBC -> Server so you get an extra layer of ADO on
top of ODBC
or you can go direct using ADO/OLEDB drivers to the server skipping ODBC in
the middle.
In high volume datbase access on WinXX machines ODBC is a very poor option
and has problems with multi tasking with most ODBC drivers. ADO (when going
direct with OLEDB drivers) does not suffer this and has better performance
then ODBC in general.
I know that some may disagree with me, but not using native toolkits (when
they are the best tool for the job) on platforms is a sign of lazy
programming and poor design. On Windows 9X/NT/2K/XP/CE, the shared library
of choice is COM and the data access method is ADO/OLEDB. DLLs are second
class citizens on Windows today. Sort of like .com instead of .exe :-)
David Botton
----- Original Message -----
From: "isaac buchwald" <isaac.buchwald@velenje.cx>
> but there is one more reason , why not to use it.
>
> If i write a package in ada , i would like to use in a
different
> invironment
> without much ado , and without a separate layer that brings in a
new
> peril of quer functioning.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: gnat ada DLL and VB
2001-08-15 13:53 ` David Botton
@ 2001-08-15 16:32 ` isaac buchwald
0 siblings, 0 replies; 16+ messages in thread
From: isaac buchwald @ 2001-08-15 16:32 UTC (permalink / raw)
ado - was used as fuss ( old Will used to use the word i presume).
but to confess , there was an allusion to ADO.
But the matter of DLL , why don't you simply say :
I can't figure it out how to do it, and neither anybody i know.
puningly yours,
isaac
"David Botton" <David@Botton.com> wrote in message
news:mailman.997883873.22464.comp.lang.ada@ada.eu.org...
> The best way to create portable libraries in general is to abstract the OS
> interface to the Ada code.
>
> When you are writing a COM object you don't have to use ADO or any COM
> objects with in your Ada code.
>
> BTW, there is no seperate layer in COM itself when used inproc (DLL base
COM
> object).
>
> As for layers in ADO (since you mentioned it), it depends on how you
> connect.
>
> ADO can do ADO/OLEDB -> ODBC -> Server so you get an extra layer of ADO
on
> top of ODBC
>
> or you can go direct using ADO/OLEDB drivers to the server skipping ODBC
in
> the middle.
>
> In high volume datbase access on WinXX machines ODBC is a very poor option
> and has problems with multi tasking with most ODBC drivers. ADO (when
going
> direct with OLEDB drivers) does not suffer this and has better performance
> then ODBC in general.
>
> I know that some may disagree with me, but not using native toolkits (when
> they are the best tool for the job) on platforms is a sign of lazy
> programming and poor design. On Windows 9X/NT/2K/XP/CE, the shared library
> of choice is COM and the data access method is ADO/OLEDB. DLLs are second
> class citizens on Windows today. Sort of like .com instead of .exe :-)
>
> David Botton
>
>
> ----- Original Message -----
> From: "isaac buchwald" <isaac.buchwald@velenje.cx>
>
>
> > but there is one more reason , why not to use it.
> >
> > If i write a package in ada , i would like to use in a
> different
> > invironment
> > without much ado , and without a separate layer that brings in a
> new
> > peril of quer functioning.
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2001-08-15 16:32 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-09 8:29 gnat ada DLL and VB isaac buchwald
2001-08-09 10:01 ` Pascal Obry
2001-08-09 12:53 ` Ted Dennison
2001-08-09 21:33 ` Pascal Obry
2001-08-10 6:06 ` isaac buchwald
2001-08-10 21:31 ` Tony Gair
2001-08-11 16:35 ` isaac buchwald
2001-08-12 22:12 ` R. Srinivasan
2001-08-13 14:50 ` David Botton
2001-08-13 18:42 ` isaac buchwald
2001-08-13 19:12 ` David Botton
2001-08-14 0:29 ` R. Srinivasan
2001-08-14 17:17 ` isaac buchwald
2001-08-15 13:53 ` David Botton
2001-08-15 16:32 ` isaac buchwald
2001-08-15 13:42 ` David Botton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox