to inser on a column a calenda I made
WITH OBJECT oBrowse:aCols[ 7]
:AddBitmap( "INVOICE_CALENDARIO")
:nBtnBmp := 1
:lBtnTransparent := .t.
* :lBmpStretch := .f.
:nwidth := 120
:nDataStrAlign := AL_CENTER
:nHeadStrAlign := AL_CENTER
:nDataStrAlign := oBrowse:aCols[ 7]:DefStyle(AL_LEFT,.f.)
:nEditType := EDIT_BUTTON
:bEditBlock := { |r,c,o,k|(XbrGetDate( o,"Seleziona una data",,1 ),oBrowse:refresh()) }
END
But it make error , how I can resolve please ?
xbrowse -get date - resolved
- Silvio.Falconi
- Posts: 4956
- Joined: Thu Oct 18, 2012 7:17 pm
xbrowse -get date - resolved
Last edited by Silvio.Falconi on Wed Jul 10, 2019 7:56 am, edited 1 time in total.
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: xbrowse -get date
Code: Select all
#include "fivewin.ch"
REQUEST DBFCDX
function Main()
local oDlg, oFont, oBrw
USE CUSTOMER SHARED
DEFINE FONT oFont NAME "TAHOMA" SIZE 0,-14
DEFINE DIALOG oDlg SIZE 800,600 PIXEL TRUEPIXEL FONT oFont
@ 20,20 XBROWSE oBrw SIZE -20,-20 PIXEL OF oDlg ;
DATASOURCE "CUSTOMER" ;
COLUMNS "FIRST","CITY","HIREDATE","AGE", "SALARY" ;
PICTURES nil, nil, "dd-mmmm-yyyy" ;
CELL LINES NOBORDER
WITH OBJECT oBrw
:nEditTypes := EDIT_GET
WITH OBJECT :HireDate
:nEditType := EDIT_BUTTON
:AddBitmap( "c:\fwh\bitmaps\calendar.bmp" )
:nBtnBmp := 1
:bEditBlock := { |r,c,o,k| XbrGetDate( o ) }
END
//
:CreateFromCode()
END
ACTIVATE DIALOG oDlg CENTERED
RELEASE FONT oFont
return nil
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
- Silvio.Falconi
- Posts: 4956
- Joined: Thu Oct 18, 2012 7:17 pm
Re: xbrowse -get date
Nages,
here not run ok
I have an array ( aItems)
here not run ok
I have an array ( aItems)
Code: Select all
@ 120, 02 XBROWSE oBrowse OF oFolder:aDialogs[1] ;
COLUMNS 3,4,5,6,7,8,9,10,11,12,13;
HEADERS "Ico","Tipo","Servizio","Q.tà","Costo","Tot p q.tà","Dal","al","Giorni","Sconto","Totale" ;
COLSIZES 30, 30,100,50,90,90,80,80,60,90,90 ;
PICTURES nil, nil,"@!","9999","999,999,999","999,999,999", "dd-mmmm-yyyy","dd-mmmm-yyyy","999","999,99","999,999,999";
ARRAY aItems ;
SIZE 100,82 PIXEL NOBORDER
ADD COLUMN TO XBROWSE oBrowse
bCalcRow := { || (oBrowse:aCols[ 6 ]:VarPut( oBrowse:aCols[ 4 ]:Value * oBrowse:aCols[ 5 ]:Value ),;
oBrowse:aCols[ 11 ]:VarPut(( oBrowse:aCols[ 6 ]:value * oBrowse:aCols[ 9 ]:value)-oBrowse:aCols[ 10 ]:value),;
CalcoloTotali(oBrowse,aGet) )}
WITH OBJECT oBrowse
:nRowHeight := 30
WITH OBJECT oBrowse:aCols[ 1]
:bFooter := { || Ltrim( Str( oBrowse:KeyNo() ) ) + " / " + LTrim( Str( oBrowse:KeyCount() ) )+" servizi" }
:lBmpStretch := .F.
:lBmpTransparent := .T.
:nwidth := 30
:bStrImage := {|| oBrowse:aArrayData[ oBrowse:narrayat][3] }
END
WITH OBJECT oBrowse:aCols[ 2]
:AddBitmap({"INVOICE_ELEMENTO",;
"INVOICE_SERVIZIO",;
"INVOICE_PACCHETTO",;
"INVOICE_LISTINO"})
:lBtnTransparent := .t.
:bStrImage := {|| GiveType(alltrim(oBrowse:aArrayData[ oBrowse:narrayat][4])) }
END
WITH OBJECT oBrowse:aCols[ 4]
:nWidth := 100
:nDataStrAlign := AL_CENTER
:AddBitmap( { FW_BmpPlus(), FW_BmpMinus() } )
// Right Button
:nEditType := EDIT_BUTTON
:bEditBlock := { |r,c,oCol| oCol:Value + 1 }
:nBtnBmp := 1
:lBtnTransparent := .t.
// Left Button
:bBmpData := { |v,lSel| If( lSel, 2, 0 ) }
:bBmpAction := { |oCol| IIF( oCol:Value>0,oCol:VarPut( oCol:Value - 1 ),) }
:bOnChange := bCalcRow
END
// colona per totale x qut riga
WITH OBJECT oBrowse:aCols[ 6]
:nFooterType := AGGR_SUM
:cEditPicture := '@ €99,999.99'
END
WITH OBJECT oBrowse:aCols[ 7]
:nEditType := EDIT_BUTTON
:AddBitmap( "c:\work\fwh\bitmaps\calendar.bmp" )
:nBtnBmp := 1
:bEditBlock := { |r,c,o,k| XbrGetDate( o ) }
END
WITH OBJECT oBrowse:aCols[ 8]
:nEditType := EDIT_BUTTON
:AddBitmap( "c:\work\fwh\bitmaps\calendar.bmp" )
:nBtnBmp := 1
:bEditBlock := { |r,c,o,k| XbrGetDate( o ) }
END
WITH OBJECT oBrowse:aCols[ 10]
:nEditType := EDIT_GET
:bOnChange := bCalcRow
END
// colona per totale riga
WITH OBJECT oBrowse:aCols[ 11]
:nFooterType := AGGR_SUM
:cEditPicture := '@ €99,999.99'
END
WITH OBJECT oBrowse:aCols[ 12]
:AddBitmap({"INVOICE_CANCELLA","INVOICE_INCOLLA"})
:nBtnBmp := 1
:lBmpStretch := .F.
:lBmpTransparent := .T.
:nwidth := 30
:nEditType := EDIT_BUTTON
:bEditBlock := { ||DeleteRow(oBrowse,aGet) }
:nHeadBmpNo := 2
:cHeader := ""
:bLClickHeader := { ||DeleteAllRows(oBrowse,aGet) }
END
:lHscroll := .F.
:l2007 := .F.
:l2015 := .T.
:nStretchCol := STRETCHCOL_WIDEST
:nColDividerStyle := LINESTYLE_LIGHTGRAY
:lAllowRowSizing := .F.
:lAllowColSwapping := .F.
:lAllowColHiding := .F.
:nMarqueeStyle := MARQSTYLE_HIGHLROWMS
:CreateFromCode()
END
Last edited by Silvio.Falconi on Fri Mar 06, 2020 8:10 am, edited 1 time in total.
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
- Silvio.Falconi
- Posts: 4956
- Joined: Thu Oct 18, 2012 7:17 pm
Re: xbrowse -get date
Sorry, now t it run ok , there was also the oldest datepick compiled!!!!
only i have no transparent bitmap also tried with pngs
only i have no transparent bitmap also tried with pngs
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC