Jump to content

Dany Marmur

  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Dany Marmur

  1. Dany Marmur

    Delphi and Java Cryptography Extension (JCE)

    I agree. JCE is a library for java. https://en.m.wikipedia.org/wiki/Java_Cryptography_Extension so you should not need it. Did you select the correct port? It's to enable SSL when using java. Windows should do it for you, at least on the client side.
  2. Dany Marmur

    http://community.idera.com/ login woes

    I gave up on that too.
  3. Dany Marmur

    Third-party controls, which have support of VCL Styles

    From the site: IMHO, you should specify that it does not handle all DevExpress controls. Better specify which controls the adapter unit supports.
  4. Dany Marmur

    DevExpress: element '' has no parent window

    I can only guess... One guess is that there is something left in some dfm 🙂 from previous versions of your project (maybe previous versions of DX too), possibly a sub-component to a DX component. The component (perhaps a LayoutControl or a GridView or a BarManager) does not create it at creation time because it does not need to BUT when things are to get destroyed the little "Handle" getter function goes and creates one (handle that is). Possibly because the streaming system wants to pick up a property. If this is true then it is a bug in the DX components, but alas one that would be very difficult to pin down even for the vendor. The call before CreatHandle looks odd. Looks like there are entries missing. It could indicate the failing component (the DropDownEdit) did not release message-handling things as it should have. Lot's of guesswork here... ouch. So what can you do? Possibly not much besides going through all dfm's and looking for something that is not used. Logging any changes you have made between production versions (if it happen at clients sites) and then compare the reports you get from MadExcept. Tedious, yes...
  5. Hello all! I have been working away at a project since this summer. Soonish (ahem) i'm going to open source it. The project requires some 3rd party non-os libs but that is not a problem as these are not included, anyone that want to use the project need active subscriptions for these libraries. I have these prereqs; Nothing to be installed in the IDE as per the project itself (i.e. it comes with no packages). All components should be working as per a "clean form" - you should be able to change properties and all, some specific limitations may apply. So basically the project is a structure with; * An hierarchy based on a DataModule responsible for SQL and dataset functionality with a "helper" transport layer. * An hierarchy based on a Vcl Form responsible for most UI and client-side stuff. Also when running the client it "drives" the creating of those DataModules. * Other resources created and managed at runtime, server side service framework - not pertinent to this post. So the idea being you inherit from the aforementioned DataModule and the Form in an "Application" space. Then change / add that inherited form as the applications main form. Here it should be possible to code away delphi-style to your heart content (some limitations... well). All of the above works rather nicely atm! Q: But then... if someone else becomes interested, builds an "Application" on top of the units that are part of the OS-project... (inheriting from included forms) well... here comes the conundrum. Will that work? I'm thinking that if i (or a contributor) makes additions/corrections to the OS project - i suspect it can become very messy to "re-inherit" the application-forms. Another way to put it - to update existing ancestor units when the bases has been updated. Q: Another question related to this is it possible to "package" such a project in any way? This would only as a convenience to the "users" of the project - (yes - i know i said above that nothing should be needed to install into the IDE, this kind of package should be optional). I know this is a little bit on the meagre side of information density for any qualified answer, flame suit on, but if anyone has any comments it's appreciated. TIA, /Dany
  6. Dany Marmur

    fast file searching, what do you recommend, please?

    Visual Code's Ctrl+F is very powerful and it visualize's the hits in a good way. Especially if you search from a "root" and "up" mostly. I use it for everything that i dare not open with the IDE (like units containing the DevExpress skinning control...), sifting through dfms and such.
  7. Dany Marmur

    We need a Delphi Language Server

    @Renaud GHIA that is a Language Server for DWScript. When it is compiled the "functionality" from DWScript is "linked" in and it is this functionality that governs what happens when you edit .pas files. So it will need to be "forked" in order to link in or connect to language stuff that is more "Delphi". But you can definitely contact Mr Budde if you have ideas or questions. He is very skilled! Another project is OmniPascal that already uses stuff for (i cannot say if it is re-implemented or linked-in) Delphi and FPC.
  8. Dany Marmur

    fast file searching, what do you recommend, please?

    So, since Uwe made that clear as i would guess (that the IOUtils is mostly "sugar") then your next move is googling around the Windows API world. I would guess that if you want to deliver faster file access that you competition you would need to write drivers, but i do not have the time to google so this is a guess. Good luck!
  9. Dany Marmur


    I know this is fastidious but i'd like a "Cancel" button to get rid of the editor when i click "Reply". I do not like editors lying around in tabs...
  10. Dany Marmur


    I must press this some more, after a couple of days, unfinished posts are still retained. So i go to read something and get confused over whether i posted the retained text, have up out decided not to post. Plz!
  11. It would be great with a check/uncheck all in this dialogue. Clicking 19 check-boxes on a phone is tricky.
  12. Dany Marmur

    First time on a phone / Forum feed selection

    I have tried bookmarks, sometimes the checks are in the URL, sometimes not. Always fiddling when there are new groups...
  13. I think i understand this thingy now! Thanks @Marco Cantu, that was a pretty down-to-the-facts post.
  14. Just realised that "Find references" works in Tokyo in my design-time heavy project. Wow! It works!!!
  15. Dany Marmur

    It's working (find references)!

    @Daniel agreed.
  16. Dany Marmur

    Detailed logging (for debugging)

    @Zacherl, i know, there are workarounds to make it log, but it becomes too shaky. That's what i meant with "a more flexible variant". Still it does not solve the problem anyway.
  17. Dany Marmur

    Detailed logging (for debugging)

    Last time (so tired of all the IFDEFs for debug logging) i tried Assert. The basic idea of Assert is nice as (correct me if i'm wrong) the compiler does not produce any code for production. But it does not help with th issue of cluttered-up sources. Also it would be nice with a version of Assert that is a bit more flexible. @edwinyzh second idea seems most apt. In my mind it will not be a small project. But i have not used the full-blown tool for these things enough to have any constructive input.
  18. Dany Marmur

    DevExpress: element '' has no parent window

    No, sorry not much. But can you reproduce this each time or is it "intermittent"?
  19. Dany Marmur

    Extracting SQL from Delphi code and DFMs

    @Bill Meyer, when i wrote the original post from my phone i confused DWSJSON and Delphi-AST. Scroll up, i have a lot of apologies for that 🙂 I used DWSJSON for this project. "Only" to parse the DFM into JSON. Again, my apologies.
  20. Same goes for my Ctrl+Shift+E to rename. After having used the menu once it works again. Happens a lot.
  21. Dany Marmur

    Extracting SQL from Delphi code and DFMs

    @David Schwartz, i see - til next time!
  22. Dany Marmur

    Extracting SQL from Delphi code and DFMs

    Yes, but a zip with an executable, then i have to code settings for the different names, i simply do not have the time now 😞. The three code-windows above is all the code except for the dpr! You can just copy paste it really. This is what i have for DWScript: https://xxx@bitbucket.org/egrange/dwscript.git This is the path to DWSJSON: https://github.com/masonwheeler/DFMJSON.git I suppose if one had the time you could VCL-ify it, add persistence and settings and some more and you'll have a neat contribution to the community. This was a very fast hack when i moved from my own dynamic SQL-repository to using DFMs. I missed the global searches i could do in my own repo. HTH, /D
  23. Dany Marmur

    Extracting SQL from Delphi code and DFMs

    @David Schwartz, RTC is here https://rtc.teppi.net/ but as i said - i only used its JSON parsing classes (value handling). You should be able to snappily change it to what comes with Delphi. Since you have DX, here's the complete visual code. Now i have pasted the whole project 🙂 BTW - you noticed my DACs are IBO, you have to change names to whatever you use. unit Forms.MainForm; interface uses Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics, Vcl.Controls, Vcl.Forms, Vcl.Dialogs, cxGraphics, cxControls, cxLookAndFeels, cxLookAndFeelPainters, cxContainer, cxEdit, dxLayoutcxEditAdapters, dxLayoutContainer, cxStyles, cxCustomData, cxFilter, cxData, cxDataStorage, cxNavigator, cxDataControllerConditionalFormattingRulesManagerDialog, cxMemo, cxGridCustomTableView, cxGridTableView, cxGridCustomView, cxClasses, cxGridLevel, cxGrid, cxTextEdit, cxMaskEdit, cxButtonEdit, dxLayoutControl, cxCustomListBox, cxListBox, cxCheckBox, cxGridWinExplorerView, dxBarBuiltInMenu, cxGridCustomPopupMenu, cxGridPopupMenu, dxLayoutControlAdapters, Vcl.Menus, Vcl.StdCtrls, cxButtons, dxSkinsCore, dxSkinOffice2013White, dxLayoutLookAndFeels; type TCollectorMainForm = class(TForm) LayoutControlMainGroup_Root: TdxLayoutGroup; LayoutControlMain: TdxLayoutControl; SQLGridLevel: TcxGridLevel; SQLGrid: TcxGrid; dxLayoutItem2: TdxLayoutItem; SQLTableView: TcxGridTableView; SQLTableViewColumnFormName: TcxGridColumn; SQLTableViewColumnStmtClass: TcxGridColumn; SQLTableViewColumnStmtName: TcxGridColumn; SQLTableViewColumnSQLText: TcxGridColumn; LogListBox: TcxListBox; dxLayoutItem3: TdxLayoutItem; FullRowHeightCheckBox: TcxCheckBox; dxLayoutItem4: TdxLayoutItem; SQLTableViewColumnStoredProcName: TcxGridColumn; SQLGridPopupMenu: TcxGridPopupMenu; PathTextEdit: TcxTextEdit; dxLayoutItem1: TdxLayoutItem; ScanButton: TcxButton; dxLayoutItem5: TdxLayoutItem; dxLayoutAutoCreatedGroup1: TdxLayoutAutoCreatedGroup; SQLStyleRepository: TcxStyleRepository; cxStyle1: TcxStyle; dxLayoutGroup1: TdxLayoutGroup; dxLayoutLookAndFeelList1: TdxLayoutLookAndFeelList; dxLayoutCxLookAndFeel1: TdxLayoutCxLookAndFeel; procedure cxCheckBox1PropertiesChange(Sender: TObject); procedure ScanButtonClick(Sender: TObject); procedure FormCreate(Sender: TObject); private procedure RefreshGrid; public { Public declarations } end; var CollectorMainForm: TCollectorMainForm; implementation uses Data.ObjectCollector; {$R *.dfm} procedure TCollectorMainForm.ScanButtonClick(Sender: TObject); begin RefreshGrid; end; procedure TCollectorMainForm.cxCheckBox1PropertiesChange(Sender: TObject); begin SQLTableView.OptionsView.CellAutoHeight := FullRowHeightCheckBox.Checked; if FullRowHeightCheckBox.Checked then SQLTableView.Controller.TopRowIndex := SQLTableView.Controller.FocusedRowIndex; end; procedure TCollectorMainForm.FormCreate(Sender: TObject); begin RefreshGrid; SQLTableView.Controller.ShowFindPanel; end; procedure TCollectorMainForm.RefreshGrid; var lCurrent: Integer; begin lCurrent := 1; SQLTableView.DataController.BeginUpdate; LogListBox.Items.BeginUpdate; try LogListBox.Items.Clear; SQLTableView.DataController.RecordCount := 0; Data.ObjectCollector.ObjectCollectoDataModule.RunCollect( PathTextEdit.Text, '*.dfm', false, procedure (aStatementInfo: TStatementInfo) begin SQLTableView.DataController.RecordCount := lCurrent; SQLTableView.DataController.Values[lCurrent - 1, SQLTableViewColumnFormName.Index] := aStatementInfo.FormName; SQLTableView.DataController.Values[lCurrent - 1, SQLTableViewColumnStmtClass.Index] := aStatementInfo.StatementClass; SQLTableView.DataController.Values[lCurrent - 1, SQLTableViewColumnStmtName.Index] := aStatementInfo.StatementName; SQLTableView.DataController.Values[lCurrent - 1, SQLTableViewColumnStoredProcName.Index] := aStatementInfo.StoredProcName; SQLTableView.DataController.Values[lCurrent - 1, SQLTableViewColumnSQLText.Index] := aStatementInfo.StatementSQL; Inc(lCurrent); end, procedure (aText: string) begin LogListBox.Items.Append(aText); end, procedure (aText: string) begin LogListBox.Items.Append(aText); end); LogListBox.ItemIndex := LogListBox.Items.Count - 1; finally LogListBox.Items.EndUpdate; SQLTableView.DataController.EndUpdate; end; end; end. ... and the dfm ... object CollectorMainForm: TCollectorMainForm Left = 0 Top = 0 ActiveControl = SQLGrid Caption = 'DFM SQL Collector' ClientHeight = 892 ClientWidth = 1507 Color = clBtnFace Font.Charset = DEFAULT_CHARSET Font.Color = clWindowText Font.Height = -11 Font.Name = 'Tahoma' Font.Style = [] OldCreateOrder = False OnCreate = FormCreate PixelsPerInch = 96 TextHeight = 13 object LayoutControlMain: TdxLayoutControl Left = 0 Top = 0 Width = 1507 Height = 892 Align = alClient TabOrder = 0 LayoutLookAndFeel = dxLayoutCxLookAndFeel1 HighlightRoot = False object SQLGrid: TcxGrid Left = 10 Top = 55 Width = 1487 Height = 793 TabOrder = 3 object SQLTableView: TcxGridTableView Navigator.Buttons.CustomButtons = <> Navigator.Buttons.First.Visible = True Navigator.Buttons.PriorPage.Visible = True Navigator.Buttons.Prior.Visible = True Navigator.Buttons.Next.Visible = True Navigator.Buttons.NextPage.Visible = True Navigator.Buttons.Last.Visible = True Navigator.Buttons.Insert.Visible = False Navigator.Buttons.Append.Visible = False Navigator.Buttons.Delete.Visible = False Navigator.Buttons.Edit.Visible = False Navigator.Buttons.Post.Visible = False Navigator.Buttons.Cancel.Visible = False Navigator.Buttons.Refresh.Visible = False Navigator.Buttons.SaveBookmark.Visible = True Navigator.Buttons.GotoBookmark.Visible = True Navigator.Buttons.Filter.Visible = True Navigator.InfoPanel.Visible = True Navigator.Visible = True FindPanel.DisplayMode = fpdmManual DataController.Options = [dcoCaseInsensitive, dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding] DataController.Summary.DefaultGroupSummaryItems = <> DataController.Summary.FooterSummaryItems = <> DataController.Summary.SummaryGroups = <> FixedDataRows.PinVisibility = rpvRowHotTrack OptionsBehavior.CopyCaptionsToClipboard = False OptionsBehavior.FocusCellOnTab = True OptionsBehavior.IncSearch = True OptionsBehavior.NavigatorHints = True OptionsBehavior.RecordScrollMode = rsmByPixel OptionsCustomize.ColumnHiding = True OptionsCustomize.ColumnHidingOnGrouping = False OptionsCustomize.ColumnsQuickCustomization = True OptionsCustomize.DataRowFixing = True OptionsData.Deleting = False OptionsData.Inserting = False OptionsView.CellAutoHeight = True OptionsView.ColumnAutoWidth = True OptionsView.HeaderEndEllipsis = True OptionsView.HeaderFilterButtonShowMode = fbmSmartTag OptionsView.Indicator = True OptionsView.ShowColumnFilterButtons = sfbWhenSelected Styles.Background = cxStyle1 Styles.Content = cxStyle1 Styles.ContentEven = cxStyle1 Styles.ContentOdd = cxStyle1 Styles.FilterBox = cxStyle1 Styles.FindPanel = cxStyle1 Styles.IncSearch = cxStyle1 Styles.Navigator = cxStyle1 Styles.NavigatorInfoPanel = cxStyle1 Styles.SearchResultHighlight = cxStyle1 Styles.FilterRowInfoText = cxStyle1 Styles.Footer = cxStyle1 Styles.Group = cxStyle1 Styles.GroupByBox = cxStyle1 Styles.GroupFooterSortedSummary = cxStyle1 Styles.GroupSortedSummary = cxStyle1 Styles.GroupSummary = cxStyle1 Styles.Header = cxStyle1 Styles.Inactive = cxStyle1 Styles.Indicator = cxStyle1 Styles.InplaceEditFormGroup = cxStyle1 Styles.InplaceEditFormItem = cxStyle1 Styles.InplaceEditFormItemHotTrack = cxStyle1 Styles.NewItemRowInfoText = cxStyle1 Styles.Preview = cxStyle1 Styles.Selection = cxStyle1 object SQLTableViewColumnFormName: TcxGridColumn Caption = 'Form Name' PropertiesClassName = 'TcxTextEditProperties' Properties.ReadOnly = True Options.FilteringPopupIncrementalFiltering = True Width = 165 end object SQLTableViewColumnStmtClass: TcxGridColumn Caption = 'Statement Class' PropertiesClassName = 'TcxTextEditProperties' Properties.ReadOnly = True Options.FilteringPopupIncrementalFiltering = True Width = 110 end object SQLTableViewColumnStmtName: TcxGridColumn Caption = 'Statement Name' PropertiesClassName = 'TcxTextEditProperties' Properties.ReadOnly = True Options.FilteringPopupIncrementalFiltering = True SortIndex = 0 SortOrder = soAscending Width = 152 end object SQLTableViewColumnStoredProcName: TcxGridColumn Caption = 'Stored Proc Name' PropertiesClassName = 'TcxTextEditProperties' Options.FilteringPopupIncrementalFiltering = True Width = 110 end object SQLTableViewColumnSQLText: TcxGridColumn Caption = 'SQL Text' PropertiesClassName = 'TcxMemoProperties' Properties.ReadOnly = True Properties.ScrollBars = ssVertical Options.FilteringPopupIncrementalFiltering = True Width = 739 end end object SQLGridLevel: TcxGridLevel GridView = SQLTableView end end object LogListBox: TcxListBox Left = 10000 Top = 10000 Width = 1467 Height = 63 ItemHeight = 13 TabOrder = 4 Visible = False end object FullRowHeightCheckBox: TcxCheckBox Left = 1405 Top = 11 Caption = 'Full row height' Properties.OnChange = cxCheckBox1PropertiesChange State = cbsChecked Style.HotTrack = False Style.Shadow = False Style.TransparentBorder = True TabOrder = 2 Transparent = True end object PathTextEdit: TcxTextEdit Left = 37 Top = 10 Style.HotTrack = False TabOrder = 0 Text = 'C:\Users\Superkey\Documents\Projects' TextHint = 'All *.dfm files in the path will be searched' Width = 1281 end object ScanButton: TcxButton Left = 1324 Top = 10 Width = 75 Height = 21 Caption = 'SCAN' Default = True SpeedButtonOptions.CanBeFocused = False TabOrder = 1 OnClick = ScanButtonClick end object LayoutControlMainGroup_Root: TdxLayoutGroup AlignHorz = ahClient AlignVert = avClient ButtonOptions.Buttons = <> Hidden = True ItemIndex = 2 ShowBorder = False Index = -1 end object dxLayoutItem2: TdxLayoutItem Parent = LayoutControlMainGroup_Root AlignVert = avClient CaptionOptions.Text = 'SQL Queries' CaptionOptions.Layout = clTop Control = SQLGrid ControlOptions.OriginalHeight = 200 ControlOptions.OriginalWidth = 250 ControlOptions.ShowBorder = False Index = 1 end object dxLayoutItem3: TdxLayoutItem Parent = dxLayoutGroup1 AlignVert = avClient CaptionOptions.Text = 'Log' CaptionOptions.Visible = False CaptionOptions.Layout = clTop Control = LogListBox ControlOptions.OriginalHeight = 97 ControlOptions.OriginalWidth = 121 ControlOptions.ShowBorder = False Index = 0 end object dxLayoutItem4: TdxLayoutItem Parent = dxLayoutAutoCreatedGroup1 AlignVert = avCenter CaptionOptions.Text = 'FullRowHeight' CaptionOptions.Visible = False Control = FullRowHeightCheckBox ControlOptions.OriginalHeight = 19 ControlOptions.OriginalWidth = 92 ControlOptions.ShowBorder = False Index = 2 end object dxLayoutItem1: TdxLayoutItem Parent = dxLayoutAutoCreatedGroup1 AlignHorz = ahClient AlignVert = avCenter CaptionOptions.Text = 'Path' Control = PathTextEdit ControlOptions.OriginalHeight = 21 ControlOptions.OriginalWidth = 121 ControlOptions.ShowBorder = False Index = 0 end object dxLayoutItem5: TdxLayoutItem Parent = dxLayoutAutoCreatedGroup1 AlignVert = avCenter CaptionOptions.Text = 'Scan' CaptionOptions.Visible = False Control = ScanButton ControlOptions.OriginalHeight = 21 ControlOptions.OriginalWidth = 75 ControlOptions.ShowBorder = False Index = 1 end object dxLayoutAutoCreatedGroup1: TdxLayoutAutoCreatedGroup Parent = LayoutControlMainGroup_Root LayoutDirection = ldHorizontal Index = 0 AutoCreated = True end object dxLayoutGroup1: TdxLayoutGroup Parent = LayoutControlMainGroup_Root CaptionOptions.Text = 'Log' ButtonOptions.Alignment = gbaLeft ButtonOptions.Buttons = <> ButtonOptions.ShowExpandButton = True Expanded = False UseIndent = False Index = 2 end end object SQLGridPopupMenu: TcxGridPopupMenu Grid = SQLGrid PopupMenus = <> Left = 1048 Top = 360 end object SQLStyleRepository: TcxStyleRepository Left = 952 Top = 320 PixelsPerInch = 96 object cxStyle1: TcxStyle AssignedValues = [svFont] Font.Charset = DEFAULT_CHARSET Font.Color = clWindowText Font.Height = -11 Font.Name = 'Courier New' Font.Style = [] end end object dxLayoutLookAndFeelList1: TdxLayoutLookAndFeelList Left = 856 Top = 368 object dxLayoutCxLookAndFeel1: TdxLayoutCxLookAndFeel LookAndFeel.NativeStyle = False LookAndFeel.ScrollbarMode = sbmClassic LookAndFeel.SkinName = 'Office2013White' PixelsPerInch = 96 end end end HTH /D