Silvio.Falconi wrote:I make a test "all together" ( csortbox, search,multisel)
Sylvio, I wanted to make some test on this sample... Is it available ?
Silvio.Falconi wrote:I make a test "all together" ( csortbox, search,multisel)
Marc Venken wrote:Silvio.Falconi wrote:I make a test "all together" ( csortbox, search,multisel)
Sylvio, I wanted to make some test on this sample... Is it available ?
nageswaragunupudi wrote:Set cSortOrder of columns you do not want to sort as "".
Example:
oBrw:aCols[ 3 ]:cSortOrder := ""
oBrw:aCols[ 4 ]:cSortOrder := ""
.....
#include "FiveWin.ch"
#include "constant.ch"
REQUEST DBFCDX
function TestTDatabase()
local oDlg, oBrw, oDbf
local cSeek:=Space(100)
local oGet
local aCols := { ;
{ "FIRST" , "Cognome",, 120},;
{ "LAST" , "Nome" ,, 120 },;
{ "STREET" , "Indirizzo",, 120 },;
{ "CITY" , "Località",, 120 },;
{ "STATE" , "Provincia",, 40 },;
{ "ZIP" , "Cap", , 60 }}
oDbf := TDatabase():Open( nil, "Customer", "DBFCDX", .t. )
oDbf:SetOrder( "FIRST" )
oDbf:GoTop()
DEFINE DIALOG oDlg SIZE 800,400 PIXEL TRUEPIXEL RESIZABLE
@ 10, 165 GET oGet VAR cSeek SIZE 280,24 PIXEL OF oDlg
@ 60,20 XBROWSE oBrw SIZE -20,-20 PIXEL OF oDlg ;
DATASOURCE oDbf COLUMNS aCols ;
AUTOSORT ;
NOBORDER CELL LINES
oBrw:aCols[ 3 ]:cSortOrder := "" //no street
oBrw:aCols[ 6 ]:cSortOrder := "" // no zip
WITH OBJECT oBrw
:RecSelShowRecNo()
:bClrStd := { || { CLR_BLACK, If( oBrw:SelectRow(), 0x88EDFB, CLR_WHITE ) } }
:nRecSelColor := nRgb( 245,244,234)
:lIncrFilter := .t.
:bOnSort := { |b,oCol| oBrw:Seek( "" ), ;
oBrw:cFilterFld := oCol:cExpr, ;
oBrw:SetFocus() }
//
:SetMultiSelectCol()
:oSeek := oGet
:CreateFromCode()
END
@ 10, 20 COMBOBOX oBrw:oSortCbx VAR oBrw:cSortOrder SIZE 100,400 PIXEL OF oDlg
ACTIVATE DIALOG oDlg CENTERED
oDbf:Close()
return nil
Marc Venken wrote:Silvio.Falconi wrote:I make a test "all together" ( csortbox, search,multisel)
Sylvio, I wanted to make some test on this sample... Is it available ?
Function USR200()
local cHelp
local oDlgMon,oBar
local oGrid
local oDTab,nRec
local aCols
local cSeek:=Space(100)
local oGet
local oFont,oBold
HelpSetTopic("Monitor del Sistema")
oDTab:=TTabAct():New()
nRec:=oDTab:Lastrec()
oDTab:SetOrder(1)
aCols := { ;
{ "USUARIO" , "Utente",, 120},;
{ "FECHA" , "Data" ,, 120 },;
{ "HORA" , "Ora",, 120 },;
{ "ACCION" , "Processo",, 200 }}
DEFINE FONT oFont NAME "TAHOMA" SIZE 0,-14
DEFINE FONT oBold NAME "TAHOMA" SIZE 0,-14 BOLD
DEFINE DIALOG oDlgMon SIZE 880,600 ;
PIXEL TRUEPIXEL RESIZABLE FONT oFont;
TITLE "Monitor del Sistema"
@ 10, 165 GET oGet VAR cSeek SIZE 280,24 PIXEL OF oDlgMon
@ 40,20 XBROWSE oGrid SIZE -20,-20 PIXEL OF oDlgMon ;
DATASOURCE oDTab COLUMNS aCols ;
AUTOSORT ;
NOBORDER CELL LINES
WITH OBJECT oGrid
:aCols[ 3 ]:cSortOrder := ""
:aCols[ 4 ]:cSortOrder := ""
:bClrStd := { || { CLR_BLACK, If( oGrid:SelectRow(), 0x88EDFB, CLR_WHITE ) } }
:nRecSelColor := nRgb( 245,244,234)
:lIncrFilter := .t.
:bOnSort := { |b,oCol| oGrid:Seek( "" ), ;
oGrid:cFilterFld := oCol:cExpr, ;
oGrid:SetFocus() }
//
* :SetMultiSelectCol()
:oSeek := oGet
:CreateFromCode()
END
@ 10, 20 COMBOBOX oGrid:oSortCbx VAR oGrid:cSortOrder SIZE 100,400 PIXEL OF oDlgMon
ACTIVATE DIALOG oDlgMon CENTERED
RETURN (NIL)
:aCols[ 3 ]:cSortOrder := nil
:aCols[ 4 ]:cSortOrder := nil
nageswaragunupudi wrote:Sorry, please try this:
- Code: Select all Expand view
:aCols[ 3 ]:cSortOrder := nil
:aCols[ 4 ]:cSortOrder := nil
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: Google [Bot] and 110 guests