PRIVATE LCALIAS,lcBillNo
lcBillNo = salemast.bill_no
LCALIAS = ALIAS()
= wget_pnam('*** RTO INVOICE ***')
SELECT salemast.bill_no,Booking.Booking_no,Booking.client,Booking.add1,booking.add2,booking.add3,booking.city,booking.pin, ;
 	client.engine_no,client.chasis_no, ;
 	saleMast.Exfactory,salemast.letter_dt,vehicle.model_no,salemast.st_rt,salemast.vehavatrt,salemast.st_amt,;
 	salemast.vehavatamt ;
FROM booking JOIN salemast ON booking.booking_no = salemast.booking_no ;
	JOIN VEHICLE ON SALEMAST.REF_NO = VEHICLE.REF_NO ;
	JOIN client ON booking.client_no = client.client_no ;
WHERE salemast.bill_no = lcBillNo ;
INTO CURSOR query
SELECT QUERY
DO prinrepo WITH 'rtoBill','','',''
USE IN QUERY
IF ! EMPTY(LCALIAS)
	SELECT (LCALIAS)
ENDIF