Such a filter works in conjunction with a button.
351 2023-07-05 06:02:07
Re: [SOLVED]is possible to make one textbox filter 2 colums (7 replies, posted in Script)
352 2023-07-04 13:05:20
Re: [SOLVED] Phone mask in table cell (6 replies, posted in Script)
example Editmask
Perfect example.
amsjunior1, I will add that you can use a mask to enter data, and store the data without formatting. To do this, the mask should be like this:
!\(00\) 0 0000-0000;0;_
In this case use the capabilities of the SQL тo display with formatting.
353 2023-07-04 08:13:02
Re: [SOLVED] Phone mask in table cell (6 replies, posted in Script)
Check your table view settings. Your SQL query is correct, returns text with formatting. Are you displaying a field named cf_celular in the table? Attach a project or a screenshot of the tabular display settings.
354 2023-07-04 08:06:16
Re: Обновление данных по запросу (2 replies, posted in Russian)
Надобно вам уточнить задачу. У вас есть запрос, который вы хотите отобразить в табличном представлении?
Если да, то вам понадобится кнопка с Action = SQL-запрос.
Форма эта?
Для какого табличного представления это нужно сделать?
356 2023-06-23 13:48:10
Re: Исключение из ComboBox (7 replies, posted in Russian)
Ещё раз добрый день, возникла такая необходимость, чтобы при редактировании записи фильтр был бы пустым, т.е. отключен, а при создании новой записи, фильтр был бы включен. Как реализовать?
Добавить обработчики на отображение и закрытие формы редактирования
procedure UD_REDACT_OnClose (Sender: TObject; Action: string);
begin
UD_REDACT.ComboBox7.dbFilter := ''; // по умолчанию фильтр снят
UD_REDACT.ComboBox7.dbUpdate;
end;
procedure UD_REDACT_OnShow (Sender: TObject; Action: string);
begin
if Action='NewRecord' then // если добавление новой записи, то
begin // добавить фильтр
UD_REDACT.ComboBox7.dbFilter := 'id_LS_STATUS = 1';
UD_REDACT.ComboBox7.dbUpdate;
end;
end;
357 2023-06-18 10:13:46
Re: Help in working through the local network (8 replies, posted in General)
To use this DBMS, it is not necessary to run a web server. You can (and should) use a database server.
https://dev.mysql.com/downloads/mysql/
358 2023-06-17 13:56:45
Re: News about the future of myvdb (35 replies, posted in General)
Hello. What is the difference between Lazarus and MVD? In screenshots the interface looks very similar and it seems they're both based on something called Delphi? Can someone explain?
The difference is that MVDB is a specialized environment optimized for creating a specific class of applications, namely: applications for working with databases MySQL and SQLite. It has a built-in report builder (FastReport) and database structure editor. And Lazarus is a universal development environment for any applications. As a result of these differences, development approaches and the speed of creating applications differ. In Lazarus, you can do everything, but slowly. In MVDB you can do fast, but only the above types of applications.
In a sense, MVDB is similar to Access - you can create data structures and forms to manage them.
359 2023-06-15 07:19:16
Re: Нужна помощь... (89 replies, posted in Russian)
А для закрытия окна предусмотрена возможность закрытия по нажатию клавиши Esc ? Или это скриптом ?
На форме ставите кнопку, настраиваете её на закрытие формы, при этом устанавливается свойство Cancel = True. Теперь такую форму можно закрыть по нажатии клавиши Ecs
360 2023-06-15 06:31:05
Re: Как построить отчет с перебором значений комбобокса? (4 replies, posted in Russian)
Есть таблица "Проекты", у которой есть поле "Статус проекта".
К этому полю привязана таблица "Статусы проекта".
На форме Проекты есть комбобокс "Статус проекта", который запускает SQL запрос, отображающий на форме проекты с выбранным в комбобоксе статусом.
Т.е. выбираем в комбобоксе какой то один статус и на форме отображаются проекты только с этим статусом.
Требуется построить отчет сразу по всем значениям комбобокса, т.е. чтобы в отчете было так:
Статус "Открытые"
Проект 1
Проект 4
Проект 8
Статус "Приостановленные"
Проект 2
Проект 3
Проект 9
Статус "В работе"
Проект 5
Проект 7
Что то не могу сообразить, каким образом решать эту задачу с помощью дизайнера отчетов. Посоветуйте, пожалуйста.
Выбираете все данные, а затем в самом шаблоне отчета настраиваете группировку данных по полю "Статус"
363 2023-06-09 09:06:30
Re: 1 МАЯ (8 replies, posted in Talks about all)
Я что-то проморгал, на какой проект сбор. Вы все таки пишите среду разработки?
Теперь могу ответить на вопрос о разработке новой среды утвердительно:
https://k245.ru/mvm/mvm-nachalo.html
364 2023-06-07 05:59:15
Re: News about the future of myvdb (35 replies, posted in General)
I would love to translate documentation and examples into English, but my economic situation does not allow me to do so much time to create the necessary volume in a reasonable time. Perhaps I would supplement my basic training course with practice for DataExpress, but I don’t understand how many English-speaking users will want to master it ...
I would like to take this opportunity to ask: who would be interested in comparing the two systems in practice after completing a basic course on creating no-code applications in My Visual Database & DataExpress?
365 2023-05-25 13:48:12
Re: Training courses for developers. Articles about application developmen (93 replies, posted in General)
DBMS choice
The My Visual Database (MVDB) development environment allows you to use two DBMSs: SQLite and MySQL. The type of DBMS used can be changed during the development process at any time. But which DBMS should you choose for your application?
366 2023-05-24 14:23:21
Re: no such table (4 replies, posted in General)
Possible reason: you copied the database from another project and the current database does not contain this table, but you still have settings from this table in the data designer in your project.
More precisely, you can say if you add your project.
367 2023-05-23 13:37:34
Re: Курсы обучения и статьи о разработке приложений (243 replies, posted in Russian)
Выбор СУБД
Среда разработки My Visual Database (MVDB) позволяет использовать две СУБД: SQLite и MySQL. Тип используемой СУБД можно изменить в процессе разработки в любой момент. Но какую СУБД выбрать для вашего приложения?
368 2023-05-20 09:13:20
Re: Training courses for developers. Articles about application developmen (93 replies, posted in General)
Production: Аccounting And Сontrol
While looking at KWORK applications for software development, I found an interesting request, apparently from a self-employed or an entrepreneur who has his own small production: we need a simple program for analyzing the profitability of the production process, in fact – accounting for the materials used and comparing with the profit received from the sale of finished products . Of course, for a complete analysis, it is also necessary to take into account the costs of electricity, rent of premises, depreciation of equipment, taxes, etc., but in some cases it is enough to control only materials and finished products.
The article was translated into French. Many thanks to Yann Yvnec:
369 2023-05-19 10:17:35
Re: Training courses for developers. Articles about application developmen (93 replies, posted in General)
Border Outpost
A single click is sometimes enough to launch an application. But sometimes the startup time is longer than the expected one or two seconds, and then the user may have the feeling that the program has frozen and something has gone wrong. This can be avoided by reducing the time until the first window appears, which is called the splash screen.
The article was translated into French. Many thanks to Yann Yvnec:
370 2023-05-15 10:40:39
Re: Update (7 replies, posted in General)
Hi v_pozidis and sparrow,
I find this discussion very interesting
I wonder how one could go about creating an automatic update.
Let's say someone updates a project and a table with related fields has been added to the new project:INITIAL SITUATION
Table name = A
Table field name A = 1CHANGES
Added table with name = B
Added field to table B with name = 2Theoretically it could be:
1) in database 'name' create table 'B'
2) in table 'name' create the field '2', text, mandatory etc.
The only thing is that I really don't know how to develop it programmatically.
const
DB_TEXT_FIELD = 1;
procedure DB_AddField(ATableName: string; AFieldName:string; AType:integer );
// добавление поля
var
tmpSQL:string;
begin
tmpSQL := 'ALTER TABLE ['+ATableName+'] ADD COLUMN ['+AFieldName+'] ';
case dbType of
DBT_UNKNOW: RaiseException('DB_AddField - не поддерживается для типа базы DBT_UNKNOW');
DBT_SQLITE: begin
case AType of
DB_TEXT_FIELD: tmpSQL := tmpSQL + ' TEXT';
else RaiseException('DB_AddField - не поддерживается тип поля: '+IntToStr(AType));
end;
end;
DBT_MYSQL: RaiseException('DB_AddField - не поддерживается для типа базы DBT_MYSQL');
end;
SQLExecute(tmpSQL);
end;
function DB_FieldExists( ATableName: string; AFieldName:string ):boolean;
// проверяет существование таблицы
var
tmpDataSet:TDataSet;
begin
case dbType of
DBT_UNKNOW: RaiseException('DB_TableExists - не поддерживается для типа базы DBT_UNKNOW');
DBT_SQLITE: begin
// Result := SQLExecute('SELECT COUNT(*) AS CNTREC FROM ( pragma_table_info('+ATableName+') WHERE name="'+AFieldName+'" )' ) = 1; // SQLite - не работает в MVDB, но работает в SQLiteStudio
Result := False;
SQLQuery('PRAGMA table_info(['+ATableName+']) ',tmpDataSet);
while not tmpDataSet.EOF do
begin
if UpperCase( tmpDataSet.FieldByName('name').asString ) = UpperCase( AFieldName ) then
begin
Result := True;
break;
end;
tmpDataSet.Next;
end;
tmpDataSet.Free;
end;
DBT_MYSQL: RaiseException('DB_TableExists - не поддерживается для типа базы DBT_MYSQL');
end;
end;
function DB_TableExists( ATableName: string ):boolean;
// проверяет существование таблицы
begin
case dbType of
DBT_UNKNOW: RaiseException('DB_TableExists - не поддерживается для типа базы DBT_UNKNOW');
DBT_SQLITE: Result := SQLExecute('SELECT COUNT(*) FROM sqlite_master WHERE type="table" AND tbl_Name="'+ATableName+'"') = 1; // SQLite
DBT_MYSQL: RaiseException('DB_TableExists - не поддерживается для типа базы DBT_MYSQL');
end;
end;
Exaples:
if not DB_TableExists('blank') then
begin
tmpSQL := //
' CREATE TABLE blank ( '+CR+//
' id INTEGER PRIMARY KEY ASC AUTOINCREMENT, '+CR+//
' length INTEGER NOT NULL '+CR+//
' DEFAULT 0, '+CR+//
' qty INTEGER NOT NULL '+CR+//
' DEFAULT 0, '+CR+//
' basic INTEGER NOT NULL '+CR+//
' DEFAULT 0 '+CR+//
'); ';
SQLExecute(tmpSQL);
end;
if not DB_FieldExists( 'order', 'comment' ) then
DB_AddField('order','comment',DB_TEXT_FIELD);
371 2023-05-13 09:09:20
Re: Training courses for developers. Articles about application developmen (93 replies, posted in General)
Cat in a bag
The style selection mechanism in My Visual Database applications is like buying a pig* in a poke: it is impossible to imagine what the program will look like with the selected style until a reboot. A few lines of code will help us solve this problem.
* in Russian - a cat
372 2023-05-12 14:18:42
Re: Training courses for developers. Articles about application developmen (93 replies, posted in General)
Analyzing modules
Storing information about projects has far-reaching goals: analysis of source code and architecture with recommendations for their optimization.
And let’s start with a simple task: extracting information about the contents of the module, in particular – finding and displaying procedures and functions.
373 2023-05-12 09:21:38
Re: Курсы обучения и статьи о разработке приложений (243 replies, posted in Russian)
Кот в мешке
Механизм выбора стиля в приложениях, созданных в My Visual Database, напоминает покупку кота в мешке: до перезагрузки невозможно представить, как будет выглядеть программа с выбранным стилем. Несколько строчек кода помогут нам решить данную проблему.
374 2023-05-10 07:52:32
Re: Help finding a post (5 replies, posted in General)
Hi Joshua,
This won't help in finding Derek's project now, but it may help in the future - I've added the ability to store project descriptions in the "Developer's guide".
https://k245.ru/en/mvdb-en/your-projects.html
Here is the version with modules and bug corrected (labDescription)
375 2023-05-10 07:24:20
Re: Software update (5 replies, posted in General)
Hello Destiny, Fabio! If you use the SQLite DBMS, then all data is stored in the sqlite.db file. Therefore, it is enough to transfer only this file, provided that the database structure has not changed. You can also migrate the settins.ini file, which stores custom settings for displaying tabular data.