Jump to content
uniGUI Discussion Forums

delagoutte

uniGUI Subscriber
  • Content Count

    422
  • Joined

  • Last visited

  • Days Won

    8

Everything posted by delagoutte

  1. Hello, Farshad/FMSoft would you be able to produce a tutorial on "how to create a custom theme" ? Where to start? tools needed ? how to proceed ? how to add in unigui adn how to deploy ?
  2. delagoutte

    How can i produce my own theme ?

    anybody could help, farshad ? other ? I have produced a theme with sencha themer based on triton. where should I put the files produced by themer ? unipackage-6.5.3 ? other directory ? We must create other files ? what should I do for my theme to appear in the list of themes available in unigui ? it's been months that I ask on different post without ever having a complete answer with good practices. Would it finally be possible to have one?
  3. Hello, i have a grid with a onselectionchange in this event i have a code like this procedure TMainForm.MygridSelectionChange(Sender: TObject); begin MyFrame.LoadData; end; I would like to know what it is the best method to be certain that I do not enter many times in parallel in this portion of code Loaddata. What is the good method for be sure TCriticalsession unisession.locksession , ... other ? If i use TCriticalSection, i think that i have this portion of code that will be locked/protected for all session but i would protect it only for the usersession.
  4. delagoutte

    adjust caption on tunibutton

    I have a tunibutton on a panel. this button is anchor on right and left. When i decrease my panel size my button size width is decrease. If the caption is too long for the button, i would like the caption to be written on 2 lines or that the font size decrease automaticly. Is it possible to do that ?
  5. delagoutte

    htmlfrane with html form

    have you try tab index : https://webcheatsheet.com/HTML/controll_tab_order.php
  6. delagoutte

    Forum very very slow...

    for me, i don't see a big difference. i often use "unread content" and i must wait 4-5 sec or little more before receive anything.
  7. delagoutte

    Hiding focus lines in TUniDBGrid with v1.50.0.1481

    i had the same problem with my custom css when i updated my project from 1.0 to 1.5 version : for resum : before (with 1.0 version and extjs 4): x-grid-row-selected , x-grid-row-...... after (with 1.5 version and extjs 6) : x-grid-item-selected, x-grid-item-......
  8. is there a method for do this ?(import in unigui a theme produce by sencha themer)
  9. delagoutte

    How can i produce my own theme ?

    i have a theme that is produce by themer. How can i add it to unigui and use it ?
  10. delagoutte

    column selection check how to fixed?

    i have a unidbgrid with option for having a column with check box for the selection. How can ido for having this column that is always display ? how to fix it ? if you have a grid with many column, -> there is a horizontal scrollbar -> if you scroll on the right, this column for selec row is not displayed
  11. delagoutte

    Unisession.AddJs for elementes inside a UrlFrame

    it is attach to this message framecommunication.zip in directory \exe\files\ there is the html frame page
  12. delagoutte

    Unisession.AddJs for elementes inside a UrlFrame

    yes, i think it is a protection/restriction problem. i had this problem, for this, i implemented a communication "protocol" between unigui application and iframe based on postmessage. i use this sample : https://gist.github.com/pbojinov/8965299 it is simple to adapt in unigu but if you want i could retreive the sample that i made.
  13. delagoutte

    Unisession.AddJs for elementes inside a UrlFrame

    if you use your webbrowser inpesctor, your grid have the good Id ?
  14. delagoutte

    translate the "Back" button

    in this example : open unit1.dfm unimform1.TitleButtons -> there is one button . there is a property caption with "Back" you could change it
  15. i have database query that could be very long in some case. for example, we can say that the query return a result after 60s (so it is too long for a good user experience on web) the query could be like that : select * from MY_TABLE WHERE MYDATE BETWEEN '01.01.2017' and '01.01.2018' the think that i would do : cut main query in sub query. i think i could do a think like this : use a grid linked to a TFDMemtable. execute a first query in a TFDQuery : select * from MY_TABLE WHERE MYDATE BETWEEN '01.01.2017' and '08.01.2017' -> add result of fdquery to the FDMemTable execute a second query in a TFDQuery : select * from MY_TABLE WHERE MYDATE BETWEEN '09.01.2017' and '16.01.2017' -> add result of fdquery to the FDMemTable ..... so with this method i gradually feed the FDMemTable Now my problem is : what is the best way to do this with unigui and show new data in client side when subquery are finished. what is the best way ? - unithreadtimer for execute sub query with a unitimer for sync client side ? (like in unithreadtimer-2 and 3 sample) -unisession.synchronize after add record in fdmemtable ? - other method ? could you give me your opinion ? have you ever done that and what approach did you use to code it ? more info, maybe it will be more clear with code : var curdate : TDate; begin curdate := IncMonth(now,-36); UniMainModule.FDQuery1.Close; UniMainModule.FDQuery1.SQL.Text := 'SELECT MyField1, MyField2, MyField3 FROM mytable WHERE Field_DATEPUB BETWEEN :DATE1 AND :DATE2'; while (curdate <now) do begin UniMainModule.FDQuery1.ParamByName('DATE1').AsDate := curdate; UniMainModule.FDQuery1.ParamByName('DATE2').AsDate := IncMonth(curdate,1); UniMainModule.FDQuery1.Open; if UniMainModule.FDMemTable1.FieldDefs.Count=0 then begin unimainmodule.CloneQueryFieldsToMemTableField(UniMainModule.FDQuery1, UniMainModule.FDMemTable1); UniMainModule.FDMemTable1.CreateDataSet; end; UniMainModule.FDQuery1.First; while not UniMainModule.FDQuery1.Eof do begin UniMainModule.FDMemTable1.Append; UniMainModule.CloneQueryDataToMemTableData(UniMainModule.FDQuery1, UniMainModule.FDMemTable1); UniMainModule.FDMemTable1.Post; UniMainModule.FDQuery1.Next; end; UniSession.Synchronize;//<<---- here i want that the temp result was sended to the client but synchronize don't work in this case sleep(1000); curdate:= IncMonth(curdate,1); end; end;
  16. delagoutte

    TUniCustomDBGrid.MoveToRow(): Unexpected Row number: 0, 3.

    i have a similar problem but i can reproduce in all case. In my grid, i apply many filter on datasource that reload data in grid and as for erich.wanker, the issue seem to be displayed randomly when we use the selectall checkbox i am using 1472 version
  17. delagoutte

    How to gradually feed a memory table. Best way for do this

    it is not really my problem but i advance i do a little test case and i use this code : procedure TMainForm.UniButton1Click(Sender: TObject); var curdate : TDate; cnt : Integer; FS : TUniGUISession; B : TBookmark; havenewrec : Boolean; begin curdate := IncMonth(now,-36); UniMainModule.FDQuery1.Close; UniMainModule.FDQuery1.SQL.Text := 'SELECT AO_KEYID, AO_REF, AO_DATEPUB FROM TB_AO WHERE AO_DATEPUB BETWEEN :DATE1 AND :DATE2 order by ao_datepub asc'; cnt := 0; while (curdate <now) do begin havenewrec := false; UniMainModule.FDQuery1.close; UniMainModule.FDQuery1.ParamByName('DATE1').AsDate := curdate; UniMainModule.FDQuery1.ParamByName('DATE2').AsDate := IncMonth(curdate,1); UniMainModule.FDQuery1.Open; try B := UniMainModule.FDMemTable1.GetBookmark; try if UniMainModule.FDMemTable1.FieldDefs.Count=0 then begin unimainmodule.CloneQueryFieldsToMemTableField(UniMainModule.FDQuery1, UniMainModule.FDMemTable1); UniMainModule.FDMemTable1.CreateDataSet; end; UniMainModule.FDQuery1.First; while not UniMainModule.FDQuery1.Eof do begin havenewrec := True; UniMainModule.FDMemTable1.append; UniMemo1.Lines.Add(UniMainModule.FDQuery1.FieldByName('AO_REF').asstring); UniMainModule.CloneQueryDataToMemTableData(UniMainModule.FDQuery1, UniMainModule.FDMemTable1); UniMainModule.FDMemTable1.Post; UniMainModule.FDQuery1.Next; Sleep(5); Inc(cnt); end; if not Assigned(B) then UniMainModule.FDMemTable1.First else UniMainModule.FDMemTable1.GotoBookmark(B); finally UniMainModule.FDMemTable1.FreeBookmark(B); end; finally if havenewrec then UniSession.Synchronize(true); end; curdate:= IncMonth(curdate,1); end; end; procedure TMainForm.UniDBGrid1SelectionChange(Sender: TObject); begin Self.Caption := UniMainModule.FDMemTable1.FieldByName('AO_KEYID').AsString; end; i add synchronize (true) on grid , i disabled editing and disabled load mask On this gif, you can see many things like the data arrived gradually but on each click on row i must have the value of first column in form caption and you can see that don't work when the data are loaded, the click have no effect. propably because grid always load data. how can i do for having a user experience more fluid ?
  18. delagoutte

    CHANGE BACKGROUND COLOR BUTTON [SOLVED]

    you could use a thing like that for change at runtime: if blue then begin UniSession.AddJS('$(''#'+MyUniGuiButon.JSId+''').removeClass(''BtnRed'')'); UniSession.AddJS('$(''#'+MyUniGuiButon.JSId+''').addClass(''BtnBlue'')'); end else begin UniSession.AddJS('$(''#'+MyUniGuiButon.JSId+''').removeClass(''BtnBlue'')'); UniSession.AddJS('$(''#'+MyUniGuiButon.JSId+''').addClass(''BtnRed'')'); end;
  19. delagoutte

    uniimage.picture.loadfromfile trouble

    Config that i used for testing your project : Dev computer : Virtual computer windows 8.1 x64 + delphi xe7 +unigui 1472 test : debug+ 32 bit Test Computer : physical pc Windows 10 x64 + chrome 69.0.3497.100 other thing : In the past i had strange problem with delphi on my unigui project. I deleted Myproject .drc and .rsm files and after all my problem disappeared maybe you have a similar problem ???
  20. delagoutte

    uniimage.picture.loadfromfile trouble

    have you got more info if you click on "further information ". on chrome devtool maybe there is more info in console, in network tab all calls have a return state 200 ? Maybe you have got an antivirus that analyze traffic and it is not fast enough or block traffic because there is a call every second ...?
  21. delagoutte

    uniimage.picture.loadfromfile trouble

    idem, i can't reproduce this issue with you sample, i try to reduce timer interval to 100ms but i can't reproduce issue client chrome 69.0.3497.100
  22. delagoutte

    uniURLFrame with SSL

    hum, i think there is no other solution than the one I proposed see : https://developer.mozilla.org/en-US/docs/Web/Security/Mixed_content/How_to_fix_website_with_mixed_content
  23. delagoutte

    About TUniRadioGroup.Caption

    try simply this function boxready(sender, width, height, eOpts) { if (sender.legend) { if (sender.legend.el) { var legend=sender.legend.el; legend.dom.setAttribute('align', 'center'); //left, right legend.dom.style['width']="auto"; legend.dom.style['margin-bottom']="0px"; legend.dom.style['border-bottom']="0px"; var legendText=legend.select('.x-fieldset-header-text').elements[0]; legendText.style['color']="green"; legendText.style['font-size']="12px"; legendText.style['font-weight']="bold"; legend.dom.style['text-align']='center'; } } }
  24. i see that with extjs 6.5 we could have advanced filter https://docs.sencha.com/extjs/6.5.0/classic/Ext.grid.filters.Filters.html (See features ->Filtering implementations) I would like this to be implemented natively in unigui
×