Link to home
Start Free TrialLog in
Avatar of chikersal
chikersal

asked on

2 ways of using ado

ado's implementation is contained in msado15.dll

now there are 2 ways of using

1'st one is including ado's header files <adoid.h>
                                         <adoint.h>
and including ado's lib file             <adoid.lib>
                       upon this i think when the program is loaded msado15.dll also gets loaded

the other way is using the #import directive
when we use second way compiler produces msado15.tlh and msado15.tli. In this case does msado15.dll gets loaded when the program starts execution or all the implementation gets transfered in tlh and tli files. I think msado15.dll still gets loaded bcos all the functions which are members of classes defined in lth and tli files further calls function which are there in msado15.dll. Am i right?
ASKER CERTIFIED SOLUTION
Avatar of jhance
jhance

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jhance
jhance

BTW, the tli and tlh files are NOT a part of the application but are used by the compiler in support of building the project.  You would not distribute them with your app.
Avatar of chikersal

ASKER

BTW, the tli and tlh files are NOT a part of the application but are used by the compiler in support
of building the project.  You would not distribute them with your app.

u say its not a part of the application but i have explored the contents of tlh and tli fiels. they contain the definition of classes that we use in ado like smart pointer calsses _recordsetPtr and _ConnectionPtr. so that code has to become a part of my exe code. isnt it. i mean compiler does compile the tlh and tli files and they have to  become a part of my exe files or not.
it should become a part of my exe code bcos suppose i call any function of a class now its obvious that the code for that function has to be a part of my exe, ofcourse if it is not implemented as a dll. so tlh and tli are not dlls. they contain classes of ADO which i use. so they should be a part om .exe file. Right or wrong?
No, the tli and tlh files are compiler supports files and are nat a part of your application.

Try this, build your application and then DELETE the tli and tlh files.  Now run your application.  It runs fine.  The tli and tlh are generated by the computer as a part of building your app.  They really are none of your concern and what is in them is irrelevant.  There are many other files in your project folder in the same category.  
No, the tli and tlh files are compiler supports files and are nat a part of your application.

Try this, build your application and then DELETE the tli and tlh files.  Now run your application.  
It runs fine.  The tli and tlh are generated by the computer as a part of building your app.  They really
are none of your concern and what is in them is irrelevant.  There are many other files in your project
folder in the same category.  


sir say i use this function of recordset

_RecordsetPtr rec;
rec.CreateInstance(__uuidof(Recordset));

now this functions implementation is there in tlh or tli files if the source code of this file doesnot become part of my exe, the how will this function work. i mean when u use a function its object code has to become a part of ur exe or it has to be attached later on as a dll, but it has to be there. without that its not posiible right?
I now have no idea what you are talking about.

Sorry, but you are focusing on an irrelevant minutae when dealing with a high-level problem.  Sort of like asking "how can I drive to Chicago when the road is paved with asphalt rather than concrete?"  Like I said, who cares?  The road is paved, that's what's important.  

In this case, who cares HOW VC++ gets code into your EXE.  The fact it that it does it.
chikersal,

You have a large number of questions have been open for some time, and our records show you logged in as recently as today. Please resolve them appropriately as soon as possible. Continued disregard of your open questions will result in the force/acceptance of a comment as an answer; other actions affecting your account may also be taken. I will revisit these questions in approximately seven (7) days.

https://www.experts-exchange.com/jsp/qShow.jsp?qid=11443178
https://www.experts-exchange.com/jsp/qShow.jsp?qid=11964778
https://www.experts-exchange.com/jsp/qShow.jsp?qid=12043279
https://www.experts-exchange.com/jsp/qShow.jsp?qid=11564958
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20104338
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20104344
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20105195
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20107021
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20117736
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20123376
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20128779
https://www.experts-exchange.com/jsp/qShow.jsp?qid=11146525
https://www.experts-exchange.com/jsp/qShow.jsp?qid=11559878
https://www.experts-exchange.com/jsp/qShow.jsp?qid=11540439
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20158555
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20174325
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20176309
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20177269
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20183746
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20184309
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20188568
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20260766
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20260773
https://www.experts-exchange.com/jsp/qShow.jsp?qid=20262003

Thanks,

Netminder
Community Support Moderator
Experts Exchange
Force/accepted by

Netminder
Community Support Moderator
Experts Exchange