xBrowse with Merge RESOURCE

xBrowse with Merge RESOURCE

Postby ronaldo » Tue Jun 01, 2010 1:01 pm

Mr. Linares, the merge using xBrowse "RESOURCE" does not work.

ex:

oBrw:City:lMergeVert := .t.

return error method City...
[b]Ronaldo Minacapelli[/b]
Sistemas, Hospedagem e Criação de WebSites
http://www.bazevani.com.br
User avatar
ronaldo
 
Posts: 139
Joined: Fri Nov 25, 2005 4:38 pm
Location: brasil

Re: xBrowse with Merge RESOURCE

Postby nageswaragunupudi » Tue Jun 01, 2010 4:36 pm

This has nothing to do with Resource.
If there is a column with header 'city', this works.

Example code:
Code: Select all  Expand view
#include 'fivewin.ch'
#include 'ord.ch'
#include 'xbrowse.ch'

REQUEST DBFCDX

function Main()

   local oDlg, oBrw

   USE CUSTOMER NEW ALIAS 'CUST' SHARED VIA 'DBFCDX'
   SET ORDER TO TAG CITY
   GO TOP

   DEFINE DIALOG oDlg RESOURCE 'TEST'

   REDEFINE XBROWSE oBrw ID 101 OF oDlg ;
      COLUMNS 'City', 'First' ;
      ALIAS 'CUST' ;
      CELL LINES

   oBrw:City:lMergeVert := .t.

   ACTIVATE DIALOG oDlg CENTERED

return nil
 

Resource:
Code: Select all  Expand view
TEST DIALOG 6, 15, 306, 227
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "TXBrowse demo"
FONT 8, "MS Sans Serif"
{
 DEFPUSHBUTTON "OK", IDOK, 252, 211, 50, 14
 CONTROL "", 101, "TXBrowse", 0 | WS_CHILD | WS_VISIBLE | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP, 4, 5, 297, 202
}
 

Screenshot:
Image
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10628
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse with Merge RESOURCE

Postby fraxzi » Wed Jun 02, 2010 7:26 am

Dear Mr. RAO,

Is there any limitation or rules to follow when using oBrw:field:lMergeVert := .T. ..?

oBrw:field must be index/the controlling index?
obrw:field must be the first column?


I tried to use it and here's some pieces of code:
Code: Select all  Expand view
...
REDEFINE XBROWSE oSupplier ID 1301 OF oFldRE:aDialogs[2] UPDATE;
         AUTOCOLS LINES CELL FASTEDIT;
         ALIAS 'supplier';
         HEADERS '_ID', 'Supplier', 'Address', 'City', 'Country', 'Last Update', 'Uploaded', 'Status';
         COLUMNS 'supplier_id', 'supplier', 'address', 'city', 'country', 'lastupdate','luploaded', 'ldeletion'
         COLSIZES 70, 350, 245, 140, 80, 200, 70;
         ON RIGHT CLICK uSupplierMenu( nRow, nCol, oSupplier )
...


MENUITEM "Arrange by CITY" ACTION ( oBrw:CITY:lMergeVert := .T. , oBrw:Adjust() ) //I tried oBrw:FullPaint() and oBrw:Refresh(.T.)


...
 



got this message after selecting the "arrange by CITY" menu

Image


Regards,
Frances
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: xBrowse with Merge RESOURCE

Postby nageswaragunupudi » Wed Jun 02, 2010 7:50 am

oBrw:field must be index/the controlling index? ... YES
obrw:field must be the first column? ... NOT NECESSARY

While creating the Browse, it is enough to say oCol:lMergeVert := .t.
If you want to do it at runtime,

oCol:lMergeVert := .t.
oBrw:lMergeVert := .t.
oCol:WorkMergeData() // call this method also
oBrw:Refresh()
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10628
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: xBrowse with Merge RESOURCE

Postby fraxzi » Wed Jun 02, 2010 8:02 am

Dear Mr. RAO,

Now I can arrange with lmergevert on runtime.


Thanks so much!


Regards,
Frances
Kind Regards,
Frances

Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
User avatar
fraxzi
 
Posts: 811
Joined: Tue May 06, 2008 4:28 am
Location: Philippines

Re: xBrowse with Merge RESOURCE

Postby ronaldo » Wed Jun 02, 2010 9:59 pm

I will do another test!

as it was in a hurry, I saw code

thanks
Ronaldo
[b]Ronaldo Minacapelli[/b]
Sistemas, Hospedagem e Criação de WebSites
http://www.bazevani.com.br
User avatar
ronaldo
 
Posts: 139
Joined: Fri Nov 25, 2005 4:38 pm
Location: brasil


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Marc Venken, nageswaragunupudi and 63 guests