Jump to content

Ronak

Members
  • Posts

    123
  • Joined

  • Last visited

  • Days Won

    5

Posts posted by Ronak

  1. hello,

     

    I used to filter in this way, this may help

     

    select ...from A,B,C,D

    where (convert(Char(8), A.RefDate, 112) between :SYMD and :EYMD)

    and (convert(Char(8), B.RefDate, 112) between :SYMD1 and :EYMD1)

    ...

     

    may google for the help for MS SQL convert function

     

    ...

    var

        SYMD, EYMD : String;
    begin

       SYMD:=FormatDateTime('YYYYMMDD', DatePkrSDate.DateTime);
       EYMD:=FormatDateTime('YYYYMMDD', DatePkrEDate.DateTime);

     

       MyQuery.Parameters.ParamByName('SYMD').Value:= SYMD;

       MyQuery.Parameters.ParamByName('EYMD').Value:= EYMD;

     

       MyQuery.Parameters.ParamByName('SYMD1').Value:= SYMD;

       MyQuery.Parameters.ParamByName('EYMD1').Value:= EYMD;

     

       MyQuery.Open;

     

    end

  2. Dear Farshad,

     

    can we have TUniActionList non visual component

     

    ActionList maintains a list of actions that can be used by components and controls, such as menu items and buttons.

     

    I see this component very useful because the Action can be enabled or disabled depending on user/login (Menu Rights) and the all buttons/menuItems

    gets enabled or disabled.

     

     

    At present  TActionList can be used but enable/disable (Enable:=True/False) has no effect on attached  buttons/menuItems.

     

    Thanks

  3. var
       fPdf:String;
    begin
       fPdf= 'abc.pdf';

       URLFrame.URL := UniServerModule.LocalCacheURL +fPdf;  // Display

     

       //    or

       UniSession.SendFile(UniServerModule.LocalCachePath +fPdf);  // open in browser (depends on browser settings)




    end

  4. In web application refresh/locate on every key-press/change of an Edit is Avoidable.
     
    Try refresh/locate when user types a complete word!
    I mean to say when user finish typing a word, or a complete sentence start locate or re-query.
     
     
    Set
    1 > Timer interval := 250                  // design Time
    2 > TimerRefresh.Enabled:=False;   // design Time
     
    procedure TMainForm.UniEdit1Change(Sender: TObject);
    begin
          TimerRefresh.Enabled:=False;
          TimerRefresh.Tag:=0;
          TimerRefresh.Enabled:=True;
    end;
     
     
    procedure TMainForm.TimerRefreshTimer(Sender: TObject);
    begin
       if WebMode then begin    //    http://forums.unigui.com/index.php?/topic/2864-unitimer-and-the-ontimer-event/
          if TimerRefresh.Tag=1 then begin
             TimerRefresh.Enabled:=False;
             ADOQuery1.Locate('Nome_cli',UniEdit1.Text,[loPartialKey]);
          end else begin
             TimerRefresh.Tag:=1
          end;
       end else begin
          TimerRefresh.Enabled:=False;     
          ADOQuery1.Locate('Nome_cli',UniEdit1.Text,[loPartialKey]);

      end;

    end;
     
    Regards
  5. When I enable the timer at run-time, at which moment it should trigger the event?

     

    1. After passage of specified interval-time (say Interval := 1000) of the timer when timer is enabled

    2. The moment the timer is enabled without waiting for time passage

     

    Thanks

  6. I have one question about the timer,

     

    at which moment the event, OnTimer needs to be executed/triggered ?

     

    1. After passage of interval-time of the timer when timer is enabled

    2. The moment the timer is enabled

     

     

    execution moment differs in VCL and WEB

    1.=VCL  and 2.= Web!

     

     

    Thanks

  7. Project1: 00000D94: 15:47:53 [HandleFileRequest]:File not found: C:\Program Files\FMSoft\Framework\unigui\ext-4.1.1a\uni-\calendar\data\CalendarStore.js
    Project1: 00000B64: 15:47:53 [HandleFileRequest]:File not found: C:\Program Files\FMSoft\Framework\unigui\ext-4.1.1a\uni-\calendar\data\EventStore.js
     

     

    I copied \uni\  to  \uni-\,   it worked

     

    Any one faced this?

     

     

  8. One more option is using Hack

     

    unit Main;
    
    interface
    
    uses
      Windows, Messages, SysUtils, Variants, Classes, Graphics,  Controls, Forms, Dialogs, uniGUITypes, uniGUIAbstractClasses...
    .
    .
    type THackGrid = class(TUniDBGrid);
    type
      TMainForm = class(TUniForm)
        Grid1: TUniDBGrid;
    .
    .
      private
        { Private declarations }
      public
        { Public declarations }
    
    implementation
    
    procedure TMainForm.BitBtnmovecolClick(Sender: TObject);
    begin
       THackGrid(Grid1).CurrCol :=  newindex ;  // Set the required columindex
    end;
    
    
    • Upvote 1
  9. procedure TFormAccountInlog.UniBitBtn_SaveClick(Sender: TObject);
    begin
      if Length(UniEdit_InlogUserName.text)=0 then begin
         ShowMessage('<br/><div align="center">Het invulllen van een gebruikersnaam is verplicht!' + '</div><br/>', procedure (res:integer) begin
           UniEdit_InlogUserName.SetFocus;

           Abort;  // Attn.
         end);
      end;
    end;

×
×
  • Create New...