Jump to content

Volk65

uniGUI Subscriber
  • Posts

    170
  • Joined

  • Last visited

  • Days Won

    4

Posts posted by Volk65

  1. Hi All!

     

    I need to intercept a link call in UniHTMLMemo or UniHTMLFrame components.
    For example, the database generates such a link <a href="MyTagName=6574">Bla..bla..bla< / a>. When I click on the link I have to get to a procedure like OnAjaxEvent, or something else and get "MyTagName=6574"
    Is that possible?

  2. Hi!

     

    1. I have UniPageControl without pages

    2. I call a procedure (Form.AddPage).  The procedure adds a UniTabSheet, create a URLFrame on the TabSheet, and sets the URL property ...

     

    As a result, the first page of the report is displayed normally, and the second page is very small :) (see image).

    The example shows this defect very clearly. In the example there are two pages, but there can be many of them (not two).

     

    Test7.rar

    post-4024-0-52168600-1530041899_thumb.png

  3. Farshad should introduce some little improvements and features in Unidbrid, so we can have direct input, editing cell and columns events and other things at CLIENT level.... (like my ancient request of partial fetching without paging....)

     

    +1

    It is really necessary functionality.

  4. Hi al!

     

    Need advice.

    There is a DB. There is a large directory that is updated rarely. If each session opens data from this directory every time-this is an extra load on the server. The idea is this:

    1. To place component to access the directory in the module, ServerModule.

    2. Once an hour, on a timer to refresh data from the server.

    3 All sessions turn to ServerModule, where the data is already loaded into memory.

    4. As a data source in ServerModule I want to use TDataSetProvider.
    I see one problem (and I don't know what's going to happen) - when a session is started to read data from ServerModule and at that moment triggered a timer to update the data.

    Is this algorithm a good idea or a bad idea? If there is another (correct) solution, then tell me how to do it correctly.

  5. I did that. Is that right?

    1.ClientEvents -> ExtEvents -> beforehide

    function beforehide(sender, eOpts)
    {
      var me=sender;
      ajaxRequest(me, '_hide', []);
    }

    2. OnAjaxEvent

    procedure TRootFrame.UniFrameAjaxEvent(Sender: TComponent; EventName: string; Params: TUniStrings);
    var RetVal: Integer;
    begin
      if EventName = '_hide' then
        FrameMessage(FM_HIDE, 0, 0, RetVal);
    end;
    

    Thanks. It works.

  6. Hi.

     

    I understand that two questions in one day is too much! :)

     

    The user clicks: http:\\brokenserver.com?prm1=val1&prm2=val2
    And in the browser, when opened, the user sees: http:\\brokenserver.com

     

    BUT, inside UniApplication I have access to UniApplication.Parameters.
    I found the topic: http://forums.unigui.com/index.php?/topic/7629-hide-parameter/
    but there it is necessary to hide every known parameter, but in the future there may be many such parameters. How to hide everything at once?

     

  7. Hi.

     

    If I understood you correctly:

    function TUniReport.ExportReport: Boolean;
    var Exp1: TfrxPDFExport;
        Exp2: TfrxJPEGExport;
        AUrl : string;
        P: Integer;
        OldFName, NewFName: String;
    begin
      Result:=False;
      case FExportType of
        retPDF:
          begin
            Exp1:=TfrxPDFExport.Create(nil);
            try
              Exp1.Background := True;
              Exp1.ShowProgress := False;
              Exp1.ShowDialog := False;
    -- Get a new file name in the cache !!!
              Exp1.FileName := UniServerModule.NewCacheFileUrl(False, 'pdf', '', '', AUrl, True);
              Exp1.DefaultPath := '';
              FRF.Export(Exp1);
    -- Now display this file in a special form to view the PDF
              frm_UReport_Preview.UniURLFrame1.URL:=AUrl;
              frm_UReport_Preview.ShowModal;
              frm_UReport_Preview.Caption:=FRepName;
              Result:=True;
            finally
              Exp1.Free;
            end;
          end;
    

    If you want to transfer the file to the client instead of displaying it:

      UniSession.SendFile(Exp1.FileName, SendAsFileName);
     

×
×
  • Create New...