Difference between revisions of "TSQLDBLibraryLoader"
(→Use and alternatives: sqlite status) |
|||
Line 26: | Line 26: | ||
== Work in progress == | == Work in progress == | ||
'''This article is still a rough draft; please compare with the official announcement by Michael Van Canneyt on the FreePascal mailing list and update this page.''' | '''This article is still a rough draft; please compare with the official announcement by Michael Van Canneyt on the FreePascal mailing list and update this page.''' | ||
+ | |||
+ | {{LCL Components Footer |TFBEventMonitor|}} | ||
+ | {{LCL Components}} | ||
[[Category:Databases]] | [[Category:Databases]] | ||
+ | [[Category:Components]] | ||
[[Category:FPC]] | [[Category:FPC]] | ||
− | [[Category: | + | [[Category:LCL]] |
+ | [[Category:Tutorials]] |
Revision as of 18:55, 24 May 2014
Overview
TSQLDBLibraryLoader is a Lazarus and FPC component that specifies the names and locations of SQLDB database libraries (DLLs/.sos/.dylibs) should be loaded from where.
Use and alternatives
For SQLDB database connectors, at least recent FPC versions try to load some default library names, but may fail. Using SQLDBLibraryLoader, you can specify the exact filename to load.
Lazarus includes an SQLDBLibraryloader component on the SQLDB tab.
SQLDBLibraryLoader needs to be called before loading/enabling TSQLConnection components.
Note that often you can a similar thing by setting the library name for the TSQLConnection descendant you are using. This does depend on that TSQLConnection descendant supporting that functionality.
Sample code
SQLDBLibraryLoader1.ConnectionType:='SQLite3';
// Note: .ConnectionType resets the LibraryName, so set LibraryName after
// setting ConnectionType!!
SQLDBLibraryLoader1.LibraryName := 'c:\path_to_sqllite_library\sqlite3.dll';
SQLDBLibraryLoader1.Enabled := true;
SQLDBLibraryLoader1.LoadLibrary;
Work in progress
This article is still a rough draft; please compare with the official announcement by Michael Van Canneyt on the FreePascal mailing list and update this page.
Return To: LCL Components | — Previous: TFBEventMonitor |