Jump to content

Fateh Bouchair

Members
  • Posts

    10
  • Joined

  • Last visited

Posts posted by Fateh Bouchair

  1. 9 hours ago, Luciano França said:
    procedure TMainForm.UniDBGrid1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
    begin
     if Key = 13 then Begin
      UniDBGrid1.CurrCol := UniDBGrid1.CurrCol + 1;
    
      if UniDBGrid1.CurrCol = UniDBGrid1.Columns.Count then Begin
       UniDBGrid1.DataSource.DataSet.Next;
       UniDBGrid1.CurrCol := 0;
      End;
    
     End;
    
    end;

     

    I need to check if value of 1st col is 'X' then goto col2 else col3 if I change the value of the 1st col if I do check from dataset 1col show always old value

     

     

  2. الان فقط عرفتك استاذ اسامة انا تتبعتك على اليوتوت في سلسلة الفاست روبورت انا هنا ابحث على طريقة لاجعل

    unidbgrid in editmode when i enter in a colmun

    شكرا مسبقا

  3. procedure UniDBGrid1ColumnSummary(Column: TUniDBGridColumn;

      GroupFieldValue: Variant);

    begin

          if Column.FieldName <> 'Your field to display count' then

             begin

                  if Column.AuxValue = NULL then Column.AuxValue:=0.00;

                  Column.AuxValue := Column.AuxValue + (Column.Field.AsFloat)

             end

    end;

     


    procedure UniDBGrid1ColumnSummaryResult(Column: TUniDBGridColumn;

      GroupFieldValue: Variant; Attribs: TUniCellAttribs; var Result: string);

    var

      I : Integer;

      F : Real;

    begin

         if SameText(Column.FieldName, 'Your field to display count') then

            begin

                 I := UniMainModule.your dataset.RecordCount;

                 Result := IntToStr(I);

                 Attribs.Font.Style:=[fsBold];

                 Attribs.Font.Color:=clGreen;

            end

         else

             begin

                  F := Column.AuxValue;

                  Result := FormatFloat('#,0.00 ', F);

                  Attribs.Font.Style:=[fsBold];

                  Attribs.Font.Color:=clNavy;

                  Column.AuxValue:=NULL;

             end;

    end;

×
×
  • Create New...