1

(3 replies, posted in General)

Hello nick

You could study the example provided in the attachment.
I use this particular approach to implementing a TV (heavily customized for my projects),
but the architecture is sufficient to get started.
However, to run it, use an older version of MVD,
since this program was created in 2020 and may not load correctly
in later versions of MVD.
It is easy to implement and modify, and basic in its functionality,
yet effective.
JB

2

(5 replies, posted in General)

Hello Crozon

I often use this feature in my MVD projects—not via a button, but through a dialog box that allows the end user to select a font from those installed on Windows. I find this approach more interactive. I use this snippet of code :

procedure Form1_OnShow (Sender: string; Action: string);
begin
    Form1.GridEmployees.Font := LoadFont;
end;

procedure Form1_Button5_OnClick (Sender: string; var Cancel: boolean);
var    FontDialog: TFontDialog;
begin
    FontDialog := TFontDialog.Create(Form1);
    FontDialog.Font := Form1.GridEmployees.Font;
    if FontDialog.Execute then
    begin
        Form1.GridEmployees.Font:= FontDialog.Font;
        Form1.GridEmployees.dbUpdate;
        SaveFont(Form1.GridEmployees.Font);
    end;
end;

procedure SaveFont(Font: TFont);
var   reg: TRegistry;
begin
     reg := TRegistry.Create;
     reg.Access := KEY_ALL_ACCESS;
     reg.RootKey := HKEY_CURRENT_USER;

     if reg.OpenKey('software\YourProjectName', true) then
     begin
          Reg.WriteString('Font.Name', Font.Name);
          Reg.WriteInteger('Font.Size', Font.Size);
          Reg.WriteBool('Font.Style.fsBold', fsBold in [Font.Style]);
          Reg.WriteBool('Font.Style.fsItalic', fsItalic in [Font.Style]);
          Reg.WriteBool('Font.Style.fsUnderline', fsUnderline in [Font.Style]);
          Reg.WriteBool('Font.Style.fsStrikeOut', fsStrikeOut in [Font.Style]);
          reg.CloseKey;
     end;

     reg.Free;
end;

function LoadFont: TFont;
var   reg: TRegistry;
begin
     result := TFont.Create;
     reg := TRegistry.Create;
     reg.Access := KEY_ALL_ACCESS;
     reg.RootKey := HKEY_CURRENT_USER;

     if reg.OpenKey('software\YourProjectName', true) then
     begin
          if reg.ValueExists('Font.Name') then result.Name := Reg.ReadString('Font.Name');
          if reg.ValueExists('Font.Size') then result.Size := Reg.ReadInteger('Font.Size');

          if reg.ValueExists('Font.Style.fsBold') then
              if Reg.ReadBool('Font.Style.fsBold') then result.Style := result.Style + fsBold;
          if reg.ValueExists('Font.Style.fsItalic') then
              if Reg.ReadBool('Font.Style.fsItalic') then result.Style := result.Style + fsItalic;
          if reg.ValueExists('Font.Style.fsUnderline') then
              if Reg.ReadBool('Font.Style.fsUnderline') then result.Style := result.Style + fsUnderline;
          if reg.ValueExists('Font.Style.fsStrikeOut') then
              if Reg.ReadBool('Font.Style.fsStrikeOut') then result.Style := result.Style + fsStrikeOut;

          reg.CloseKey;
     end;

     reg.Free;
end;


JB

3

(7 replies, posted in General)

Hello Nicklode
There is a page xith tutorials for LRAD, but all is in chinese language (or at leat asiatic language).
I've no tried to translate with Google or a professionnal translator, it's practically a mission impossible
Sorry

Regarding Destiny:
Hello Crozon
I was unable to transfer MVD data to Longtion, or vice versa.
Too many error messages.

JB

4

(7 replies, posted in General)

Hello Nicklode

I used LRB (and its little brother, Longtion Application Builder).
It was efficient, relatively easy to use, and allowed for the generation of executables.
The early versions didn't support calculated fields yet, which was a bit of a drawback.
The purchase price is still a bit steep ($300 for LRB and $400 for LAB).
As soon as MVD was released, I adopted it immediately because it was so inherently efficient and truly easy to use.
Now that this superb software is no longer being updated, I’ll likely lose interest in it (though I remain very fond of it),
and I might go back to LRB (which isn't cheap but is still evolving).
But I will almost certainly turn to Lazarus, which I’ve also been using for a few years (and which is free, backed by a very strong and efficient team of volunteers).
MVD will likely face a slow decline due to a lack of new features, but competitors (both free and paid) are already out there.
It's a shame!

JB

5

(6 replies, posted in General)

Hello FMR
Well seen
Correction made.
JB

6

(3 replies, posted in General)

Hello Nicklode
Do some research on the forum.
Derek created a project showcasing different types of chart layouts (but I don't remember the name).
JB

7

(3 replies, posted in General)

Hi Sparrow
Thanks for your quick reply.
Indeed, it's an element created on the fly, so I can't do anything with it.

Therefore, I'm going to look at an element you created, namely using this element but integrated into a form.
That way I can directly interact with this modal form.
That might solve my problem.
Thanks again,
JB

8

(3 replies, posted in General)

Hello everyone, what is the name of this object? It allows you to create a parent or child in a Treeview.

When I validate an entry, it always reappears with the created child (in ShowModal mode), and I have to click Cancel.

I'm trying to disable this reappearance using a statement like 'ThisThing.Visible := False;' or a similar statement that does the job. Since I don't know its name, I'm stuck.

Thank you for your help.
JB

9

(6 replies, posted in General)

Hello everyone!

Here's a little document I always keep handy that might be useful for anyone wanting to customize the colors of their MVD projects.
Enjoy!

JB

10

(8 replies, posted in General)

Hello Destiny, Hello Derek

Demat Crozon :
Excellent partage
La dernière fois je n'avais pas pu le télécharger entièrement.
Cette fois ci est la bonne
Merci encore
JB

11

(10 replies, posted in General)

Hllo Poizidis
Try this, it's OK everywhere I use it in my projects :

procedure Form1_Button1_OnClick (Sender: TObject; var Cancel: boolean);
begin                                                                             // mbYes est 6 - mbNo is 7 - mbCancel est 2
   If 7 = MessageDlg('Vous voulez quitter l''application ?', mtConfirmation, mbYes + mbNo, 0) then
      Cancel := True;
end;
JB

12

(17 replies, posted in General)

Hello Adam, Hello Derek

As is often the case in MVD, the Windows environment in which the applications run is the one calling the shots.
Often, there's no other option than to "go behind the scenes," as Derek suggests.
JB

13

(2 replies, posted in Script)

Hello Derek
I finally found the program mentioned in my last post.

Well, I'm going to use your project since it's so much simpler.
You solve the problem with just two lines of code.

Thanks again, Derek, and have a good day.
Best regards,
JB

14

(2 replies, posted in Script)

Hello all
I downloaded a simple little program from the MVD forum quite a while ago that converts minutes to hours.

I can't remember its name or even find it on the forum.

Does anyone still have it on their computer?
If not, I'll create a function in MVD and put it behind a button.

Thanks in advance.
JB

15

(1 replies, posted in General)

Hello Ansel
Please, follow this likn
https://myvisualdatabase.com/forum/view … hp?id=9494
JB

16

(3 replies, posted in General)

Hello Ansel

Konstantin has given a king of answer :
"The appearance of the TProgressBar component starting from Windows 7 is determined by the operating system settings. But if you use styles, then the progress bar becomes stylish too."
JB

17

(11 replies, posted in General)

Hello Konstantin
Thanks for your reply.
Indeed, it's a complex system, and as soon as there are too many overlaps between parents and children, management becomes complicated. I wasn't familiar with the Cartesius method; it's incredibly complex!

So I'll stick with MVD.
Thanks again.
JB

18

(11 replies, posted in General)

Hello Derek
My report works perfectly from a grid, just like you and Konstantin did.

Similarly, using the Fastreport documentation and snippets found online in Delphi that I adapted for MVD, I finally got what I wanted (you can even hide blank pages).

Out of curiosity, and without meaning to copy you, what syntax did you use to achieve this?

Thanks and have a good day.
JB

19

(11 replies, posted in General)

Hello Derek
My project, which uses FastReport and Treeview, is too large to attach to MVD.

I'm looking for a way to zip it and I'll send it to you so you can test your ideas.

JB

20

(11 replies, posted in General)

K245
Hello K245

I did the same as you, I used a classic tablegrid, and it works.

But out of curiosity, I'd like to know how to prevent the parent node from being displayed if it doesn't contain any data, and only display the children of those parents.
See the attachment
JB

21

(11 replies, posted in General)

Hello all
Has anyone ever tried creating a report from a Treeview?

I tried the traditional method, but the problem is that it consistently creates a blank page displaying the parent trees without any data (and even with data).
Is there a way to display only the child trees?
I consulted the official FastReport documentation, but couldn't find any answers (if I type 'Treeview' into their search engine, it returns no results).
Thanks in advance for your help.
JB

22

(3 replies, posted in General)

Hello Ansel

Find on the forum.
Derek has made a project with different kinds of charts, but I don't racal its name
JB

Hello Prahousefamily
It's true that the forum will slowly die out for lack of active members.

I anticipated this a long time ago, ever since Dmitri left, and since then I've created an application (using MVD) in which I've compiled a large number of snippets, as well as a folder I called MVD Tests where I've gathered a huge number of MVD projects in all areas, from which I continue to create new projects.

As for scraping the MVD forum site, I'm not sure if that's even possible. We'll see.
JB

24

(1 replies, posted in General)

Hello Vicegerent
Give us more information.
Is your image an integral part of the database (via a DBImage)?
How are you storing it in the database: directly integrated via StoreFile (not a good idea) or in a dedicated folder via LinkFile and CopyTo?
You should consider these methods.
JB

25

(16 replies, posted in General)

Hello
So this would suggest that your program isn't necessarily the problem.

You could uninstall your version of MVD (cleanly, so nothing is left in the registry) and reinstall it, or even use the previous version of MVD and test your program again.

JB