Topic: Версия 4.2
Версия 4.2
Скачать:
http://myvisualdatabase.com/download/myvisualdb.exe
Что нового?
- Добавление маркера на карту с помощью отдельной формы, с дополнительными данными.
примеры: http://myvisualdatabase.com/forum/viewtopic.php?id=4037
- Добавлены классы TWebGMapsGeocoding и TWebGMapsReverseGeocoding
примеры:
http://myvisualdatabase.com/forum/misc. … download=1
http://myvisualdatabase.com/forum/misc. … download=1
- Добавление переменных в отчет с помощью скрипта
пример:
procedure Form1_ButtonReport_OnClick (Sender: TObject; var Cancel: boolean);
begin
Form1.frxReport.Variables.Clear;
Form1.frxReport.Variables[' ' + 'My Category 1'] := Null;
Form1.frxReport.Variables['My Variable 1'] := 10;
Form1.frxReport.Variables['My Variable 2'] := 20;
Form1.frxReport.Variables['My Variable 3'] := '''Hello''';
end;
- Добавлена функция ShowRecordEx, для заполнения формы данными из другой MySQL БД
пример:
var
MySQL: TMyConnection;
procedure Form1_Button1_OnClick (Sender: TObject; var Cancel: boolean);
begin
if MySQL.Connected then
begin
ShowRecordEx(frmAddEdit, 'tablename', 1, MySQL); // 1 - id of record in the table
end;
end;
procedure Form1_OnShow (Sender: TObject; Action: string);
begin
MySQL := TMyConnection.Create(Form1);
MySQL.Options.UseUnicode := True;
MySQL.Server := '127.0.0.1'; // ip address of MySQL server
MySQL.Port := 3306;
MySQL.Username := 'username';
MySQL.Password := 'password';
MySQL.Database := 'databasename';
MySQL.LoginPromt := False;
try
MySQL.Connect;
except
ShowMessage('Can''t connect to database.');
end;
end;
procedure Form1_OnClose (Sender: TObject; Action: string);
begin
MySQL.Disconnect;
MySQL.Free;
end;
- Добавлена функция GetEnvironmentVariable
пример:
procedure Form1_Button2_OnClick (Sender: TObject; var Cancel: boolean);
var
s: string;
begin
s := GetEnvironmentVariable('HOMEPATH');
ShowMessage(s);
end;
Доступные переменные среды:
https://ru.wikipedia.org/wiki/Переменная_среды_Windows
Для класса TWebBrowser добавлен метод GetElementById
procedure Form1_Button1_OnClick (Sender: string; var Cancel: boolean);
begin
Form1.Edit1.Text := WebBrowser.GetElementById('radio1', 'value');
end;
- Исправление ошибок.