I have been spending hours to figure out how getting Library Manager in my form. Here what I did:
ForceCurrentDirectory := true;
DgrLibraryFolderFiler1.BaseFolder :=
ExcludeTrailingPathDelimiter(ExtractFilePath(Application.ExeName)) + '\Libraries';
DgrLibraryManager1.LoadLibraries;
RegisterGraphicFileFormats(DefaultGraphicLib);
Application.ShowMainForm := false; //DiagramEditor1.OnCreateDesigner := EditorCreate;
DiagramEditor1.Execute;
Every thing goes fine and the editor opens but without showing the Library manger section. Even If I try to copy a group of blocks by clicking on the Right mouse, it happens that the option "Add to library" is dimmed inside the popupmenu. Please What did I miss?
Thank you for reply
I invite you to do this:
Open new Vcl Project(Iam working with Delphi 10 Seattle.
Add the component: AtDiagram1 , dgrlibraryFolderfiler, fgrlibrarymanager
Past the below lines in the oncreate Page event of the form:
DgrLibraryFolderFiler1.BaseFolder := ExcludeTrailingPathDelimiter(ExtractFilePath(Application.ExeName)) + '\Libraries';
** DgrLibraryManager1.LoadLibraries;**
** RegisterGraphicFileFormats(DefaultGraphicLib);**
** Application.ShowMainForm := false;**
** DiagramEditor1.Execute;**
You probably should add dgrClasses to uses units
Run the program!!!
LibraryManageer section under Layer section is absent
if you try to add a grouped blocks by RightMouse clicking, the option" add to library is dimmed!!
I still don't understand!
I have sent you the test project, did you bother to open it? It has the source code you sent me. It works. Please continue from there and let me know how it goes, thank you.
Yes!. It seems I forgot to assign diagrameditor1.LibManager to DgrLibraryManager1... now my project is exactly simillar to the one you sent to me.
I appriciate as as always your valuable support!
Thank you ver much