FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Converting sample test of Tplan
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 07:47 AM
Mr Rao,

I'm afraid that Daniel Garcia Gil made me to release more different from that you published but I tested the source you have pubblished

first error.

I don't see any date in the date controls


on METHOD BuildDialog why you use ::Commit() instead of oReserva:save() ?

Second Error
when you open for the first time it is possible that you manage to create the reservation, if you re-open for the second time you do not see the reservation created and you cannot make any more



in fact the procedure creates the record but does not go to save anything as seen in the figure

Third error



on METHOD MoveReservation( oData, nRowId, oPlann ) there is an error when go to save as you can see on picture


Four error
When I try to resize a bar there is strange error as ou can see here





Another test



when you insert a record on plan you see the reservation on window but on archive reserva.dbf you can see only a empty record with no data info
that's why when you exit and re-enter the program you don't see any reservation created


So it's not the error of the indexes but the error is perhaps somewhere else

the error is not in the Tplan class because I assure you that the class works very well
if you want I can show you an example where everything works fine but not with tdatabase / tdata but only in single-user mode (reserva->)
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 08:25 AM

Ok.
Now you have the sample converted using TDatabase

Regards



G. N. Rao.

Hyderabad, India
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:08 AM
nageswaragunupudi wrote:Ok.
Now you have the sample converted using TDatabase


but not run with tdatabase - instead with old system run ok as you can see here

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:11 AM

It is working here for me with tdatabase

Please use the source code I posted as it is without changes and let us know.

Regards



G. N. Rao.

Hyderabad, India
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:17 AM
Nages,
on METHOD BuildDialog( oPlan, dCheckIn, dCheckOut )

I made

IF lSave
if lNew
::Append()
oRec:= ::record(.t.)
else
::Seek( oPlan:GetRowID() + DToS( dCheckIn ) )
oRec:= ::record()
endif

oRec:DATE = Date()
oRec:ROOMS_ID = oPlan:GetRowID()
oRec:CHECK_IN = dCheckIn
oRec:CHECK_OUT = dCheckOut
oRec:STATUS = StrZero( oCbx:nAt, 2 )
oRec:GUEST = cName
oRec:save()



now the record is saved on archive


Now the method METHOD ResizeReservation( oData, nRowId, oPlann ) not make error but not save on date right date
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:20 AM
nageswaragunupudi wrote:It is working here for me with tdatabase

Please use the source code I posted as it is without changes and let us know.



Nages I used your files you published in this forum and not run as I sad you on this message

viewtopic.php?f=3&t=37337&start=15#p223105

I post also the images with the errors
you said that it works with td but you actually actually see it on the screen when you enter a new booking but in reality the procedure only saves an empty record and not the data you entered, I'm trying to make you understand where it is the error
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:42 AM
Now seems run ok I changed BuildDialog

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 09:47 AM

I edited and revised the sample01.prg.
Please test the revised program.

Regards



G. N. Rao.

Hyderabad, India
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Fri Jun 21, 2019 10:10 AM
nageswaragunupudi wrote:I edited and revised the sample01.prg.
Please test the revised program.


I saw...
why I cannot use oRec:record(.t.) ?

I allready have the error on datepick I not see the date but only //
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Sat Jun 22, 2019 10:00 AM
Error on Modify I not see the data info





Sure not need oRec:record() instead of oReserva:xxxxx ?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Sat Jun 22, 2019 10:35 AM
when go to search not search right as you can see here



on Plan there is "Antonio Linares" but the seek is positioned on first record of database

I change the index INDEX ON ROOMS_ID + DToS( CHECK_IN )+ALLTRIM(TYPE) TAG room_in because I add a new field on Reserva.dbf Type

and then on dialog I make the seek

::SetOrder( "room_in" )
::GoTop()
::Seek( oPlan:GetRowID() + DToS( dCheckIn )+ALLTRIM(cTipo) )

any solution please
I need have the room_id and room type because I have diiferent type of rooms having the same number
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM

Re: Converting sample test of Tplan

Posted: Sat Jun 22, 2019 11:00 AM

Some time ago I tried to contact Daniel Garcia Gill also through Antonio but he seems to have vanished into thin air

I am very worried that something has happened to him.

Daniel must make people feel and say "I'm here and I'm fine !!!"

I am aware of the facts and situations that exist in Venezuela, even though Daniel should live in the north of Venezuela and I am also worried because I have many relatives in Caracas and Barquisimeto y do lara.

In Daniel's class even if in the archive Rooms.dbf there is the type field then in reserva.dbf it is not mentioned. My problem is precisely that my client has several rooms with the same number but with the different type.

So I thought I'd modify the Room_ID string with the first character of the room description string and then the room number so I could have it now:

O001 which is different from P0001

then on reserva.dbf I go to store the new RoomdID and now the index and the seek positioning in the archive :: oReserva seems to work well.

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com

Continue the discussion