FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Dividing a Receipt ticket
Posts: 883
Joined: Thu Dec 24, 2009 12:46 AM
Dividing a Receipt ticket
Posted: Thu Sep 15, 2011 06:23 PM

Hi all,

I am trying to divide a receipt ticket, which I have in a temporary DBF File, I just took a loot at \samples\testdrp6.prg, and that sample does exactly what I need, but I am afraid I can't use it, because I asume that it will be too difficult to achieve Click and Hold in a TouchScreen Monitor...

Does anyone has a sample on how to send the selected registers to another browse that will be willing to share??? Ideas are also welcome!!!

=====>

Bayron Landaverry
xBasePHP.com
(215)2226600 Philadelphia,PA, USA
MayaBuilders@gMail.com
Guatemala

FWH25.06--Harbour 3.0.0--BCC7.7--UEstudio 10.10
Windows 10

FiveWin, One line of code and it's done...

Posts: 3022
Joined: Fri Oct 07, 2005 01:45 PM
Re: Dividing a Receipt ticket
Posted: Thu Sep 15, 2011 07:35 PM

I'm confused by the question. "Receipt" and "Registers". Can you please clarify by example or email me direct at timstone@mlsdg.onmicrosoft.com

Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
Posts: 883
Joined: Thu Dec 24, 2009 12:46 AM
Re: Dividing a Receipt ticket
Posted: Thu Sep 15, 2011 07:57 PM
Hi Tim,
I call the columns FIELDS,
and the lines REGISTERS or RECORDS (I may call them wrongly???, Let's call'em RECORDS)

I will like to; having two Browses, send the selected Records in one to the other and viceversa by clicking a button ... kind of erase the selected records in one browse and add it to the other browse....


Using a available picture just to represent what I try to achieve...

I can't provide an example because I have not started anything yet.... I have a pretty bad FLU, and I am just trying to save some time!!!

Thanks for your time....

=====>

Bayron Landaverry
xBasePHP.com
(215)2226600 Philadelphia,PA, USA
MayaBuilders@gMail.com
Guatemala

FWH25.06--Harbour 3.0.0--BCC7.7--UEstudio 10.10
Windows 10

FiveWin, One line of code and it's done...

Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: Dividing a Receipt ticket
Posted: Fri Sep 16, 2011 08:35 AM

You can do it by using two scopes, one for each browse. To move a record from one browse to the other just change the value of the scoped field and refresh the browses.

EMG

Posts: 3022
Joined: Fri Oct 07, 2005 01:45 PM
Re: Dividing a Receipt ticket
Posted: Fri Sep 16, 2011 04:07 PM

You could also use filtered indexes. One field has a logical value, and if it is .t., then it is included in the index. If it is .f., it is included in an alternate index. You can then have browse 1 include the .t. records, and browse 2 include the .f. records. When you change the value ( using your arrow buttons ), the logical value changes, the indexes automatically update, and an oBrw:update( ) will reflect the changes in the browse ( update both browses ... )

Tim

Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
Posts: 3022
Joined: Fri Oct 07, 2005 01:45 PM
Re: Dividing a Receipt ticket
Posted: Fri Sep 16, 2011 04:19 PM

Bayron,

Think of a browse just like a spreadsheet. Your fields are "Columns" ( thus source code relevant to it will be "Col", like aCols, etc ) and your records are "Rows". Individual data values are held in "Cells". In fact, in current usage, a Database is the group of .dbf files used in a project, and each individual file is a "Table". These are derived from SQL that lumps all our data into a single file package, and each set of data is held in a table.

Once you think in these terms, it will make understanding any source code you see easier. The hierarchy is:

Database
    Table
       Rows
       Columns
          Cells

The best way to understand how to use the capabilities of FWH is through the source code ( provided ). I hope this explanation of key words helps you to more easily navigate that code, and see the power available to you.

Tim

Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
Posts: 883
Joined: Thu Dec 24, 2009 12:46 AM
Re: Dividing a Receipt ticket
Posted: Sat Sep 17, 2011 01:23 AM

Enrico and Tim, I like both your Ideas of scopes and indexes... I will see what I can do to get this project done...

Thank you...

=====>

Bayron Landaverry
xBasePHP.com
(215)2226600 Philadelphia,PA, USA
MayaBuilders@gMail.com
Guatemala

FWH25.06--Harbour 3.0.0--BCC7.7--UEstudio 10.10
Windows 10

FiveWin, One line of code and it's done...

Continue the discussion