Q: FireDac error 314 - but DLLs are in program directory I am getting when trying to access a MySql database :

[FireDac][Phys][MySQL]-314. Cannot load vendor library [libmysql.dll
  or libmysqlld.dll]

This did not previously happen with this (unchanged) code, however, I have upgraded to Windows 10 and had to reinstall Delphi XE8, so it is obviously a system configuration matter. 
In order to try to solve the problem, I copied both of those files into c:\windows\sysytem32.
When that did not seem to work, I copied them into \win32\debug, which is where the generated .EXE resides.
I imagine that I am doing something rather stupid, but can't see what.

A: The proper solution is to place the driver file (eg., libmysql.dll) in your application's folder, or to place the installation location in your FDDrivers.ini file:
[MySQL]
Vendor=<folder>\libmysql.dll

(Recent versions of the documentation seem to use VendorLib instead of Vendor in the INI file.)
See the RAD Studio documentation topics Configuring Drivers (FireDAC) and Connect to MySQL Server (FireDAC) for more information.

A: Let me to answer in two point.


*

*Developing, live database connection!
Hope you have on your data module an "TFDPhysMySQLDriverLink" component.
Click this component and browse your LibMySQL.DLL into VendorLib. Should be work. But only in design time.

*Runtime. Hopefully your DM created firstly in your project.
In the DM's OnCreate event, you have to disconnect your library (I always ran my project with no database connection) and replace your "TFDPhysMySQLDriverLink"'s Vendorlib to LibMySQL.DLL (which is copied your  which is copied where the generated .EXE resided)



Have a nice day!
