Jump to content

FlavioMacedo

uniGUI Subscriber
  • Posts

    69
  • Joined

  • Last visited

Posts posted by FlavioMacedo

  1. I'm trying without any success to do this with URLFrame1.

    Returns me an ajax error like below:

    OB4F.iframe.contentWindow.document.getElementById ("download").style.display = "none";OB4F.iframe.contentWindow.document.getElementById ("secondaryDownload").style.display = "none";OB4F.iframe. contentWindow.document.getElementById ("openFile").style.display = "none";OB4F.iframe.contentWindow.document.getElementById ("secondaryOpenFile").style.display = "none";OB4F.iframe.contentWindow.document. getElementById ("viewBookmark").style.display = "none";OB4F.iframe.contentWindow.document.getElementById ("secondaryViewBookmark").style.display = "none";OB4F.iframe.contentWindow.document.getElementById ("documentProperties ").style.display = "none";

    my code is as follows:

    procedure TppCotacao.UniFormBeforeShow(Sender: TObject);
    var
       lPDFDevice: TppPDFDevice;

    begin

       lPDFDevice := TppPDFDevice.Create(nil);
       try
         lPDFDevice.PDFSettings := Compras_Cotacao.PDFSettings;
         lPDFDevice.FileName := UniServerModule.NewCacheFileUrl(False, 'pdf', '', '', AUrl, True);
         lPDFDevice.Publisher := Compras_Cotacao.Publisher;
         Compras_Cotacao.PrintToDevices;
         UniURLFrame1.URL := AUrl;
         lPDFDevice.FileName := UniServerModule.StartPath + 'files\' + MainModule.UniMainModule._company_code + '\Work\' + MainModule.UniMainModule._Document + '-C' + '.pdf';
         Compras_Cotacao.PrintToDevices;
         MainModule.UniMainModule._sAnexo1 := lPDFDevice.FileName;
       finally
         lPDFDevice.Free;
       end;
    end;

    procedure TppCotacao.UniURLFrame1FrameLoaded(Sender: TObject);
    begin

       // download button
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("download").style.display = "none"');
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("secondaryDownload").style.display = "none"');

       // open file button
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("openFile").style.display = "none"');
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("secondaryOpenFile").style.display = "none"');

       // view bookmark button
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("viewBookmark").style.display = "none"');
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("secondaryViewBookmark").style.display = "none"');

       // documentProperties
       UniSession.AddJS (UniURLFrame1.JSName + '.iframe.contentWindow.document.'
            + 'getElementById ("documentProperties").style.display = "none"');


    end;

  2. Good morning.
    I would need to limit in the uniurlframe some users the possibility of downloading.
    It would disappear with the download options and also the printing of the context bar or even the whole bar.

     

    image.thumb.png.d841ea7cb7c22aeb61d68b05cbf69c96.png

  3. In a calendar I have several types of events such as prospects and customers (there are more than 20 different types)
    I would like to identify each one of them in a different color.
    One question... Is there a limit for calendars? If there isn't one, I can start with several calendars knowing that I can have more than 20 different ones.

  4. I need that when I present the text in the htmlmemo the cursor is positioned at the end of the window and not at the top.
    How do I position at the end of the screen with the html?
    PS: He is creating a scroll but in the presentation it is positioned on the first line and I need it to be positioned on the last.
    If you can help me with this doubt I would appreciate it.
    TFA
    

     

    Capturar.PNG

  5. Hello everybody.
    Does anyone have any way to monitor user activities in an inigui dll in ISAPI.
    I would like to know in real time who is in the application for example.
    I tried integration with google analytics but it didn't work well. It looks very outdated.

    If anyone has any component or any example I appreciate it.

    TFA

  6. Good Morning.
    Is there any way for code to simulate pressing a grid action button? The procedure is the one below that I need to simulate pressing the buttonid = 0

    procedure TUniVen01u.UniDBGrid2ColumnActionClick (Column: TUniDBGridColumn; ButtonId: Integer);
    var
        Request: Integer;
    begin
        case ButtonId of
           0:
              begin
                  ........
              end;
        end;
    end;

  7. As the print option is not available but it works there is a table where I can see the options available even without the presentation with combo?

  8. Good morning my friends.

    I use the icons in the iconcls by default (they are very good) but I miss some icons such as the print. I would have to implement these options myself or these icons are fixed within the FMSoft code.

    Thank you for your attention and I count on you.

    Big hug.

    iconcls.PNG

  9. Bom Dia meus amigos.

    Estou usando o filtro no unidbgrid de uma maneira perfeita, mas em um certo ponto de execução preciso do código para limpar a pesquisa usada em uma das células da grade. Pode ser simulado via código para pressionar o botão ao lado do UniDBLookupComboBox na grade do filtro para limpá-lo. Como faço isso via código?2064233915_clearbutton.thumb.PNG.55ea5263cc757d3caccf21aa5246fc2d.PNG

  10. I am trying to implement theme change by the user in the same way as the example but in my it does not change the theme when I choose combobox and also does not restart the application. What is missing? Is there any kind of hidden code?

×
×
  • Create New...