Dear Sir,
On Writing The Following Code The Error IS Generated "Invalid Operation On cursor". Then When I am Rewriting the code then it workin Perfectly.
IF FILE(DBF('xor'))=.T. then
SELECT xor
USE
endif
Select accesreq.companyname,accesreq.reqno,accesreq.department,accesreq.unit,;
accesreq.dyissparty,accesreq.reqname,accesreq1.itemcode,accesreq1.itemname,;
accesreq1.size, accesreq1.unitofmeas, accesreq1.qty,accesreq1.stylename,;
accesreq1.buordno,accesreq1.buname from accesreq inner join accesreq1;
on accesreq.reqno=accesreq1.reqno into cursor xor1 readwrite;
where accesreq.reqno=thisform.pageframe1.page1.combo1.Value
ALTER TABLE xor ADD COLUMN flag l
REPLACE all flag WITH .t. for !EOF()
thisform.pageframe1.page2.grid1.recordsource="sele flag,stylename,buname,buordno,itemcode,itemname,size,unitofmeas,qty from xor into cursor x"
thisform.pageframe1.page2.Refresh()
thisform.pageframe1.ActivePage=2
WITH thisform.pageframe1.page2
SELECT xor
.text1.value=xor1.reqno
.text2.value=xor1.department
.text3.value=xor1.unit
.text4.value=xor1.dyissparty
.text5.value=xor1.reqname
.text6.value=DATE()
.text7.value=xor1.companyname
ENDWITH
The Error is generated at line "ALTER TABLE xor ADD COLUMN flag l". Now will any one pls suggest me why its happening and what is the solution for it.
Waiting for replies.
Thanx & Regards
Chandan
On Writing The Following Code The Error IS Generated "Invalid Operation On cursor". Then When I am Rewriting the code then it workin Perfectly.
IF FILE(DBF('xor'))=.T. then
SELECT xor
USE
endif
Select accesreq.companyname,accesreq.reqno,accesreq.department,accesreq.unit,;
accesreq.dyissparty,accesreq.reqname,accesreq1.itemcode,accesreq1.itemname,;
accesreq1.size, accesreq1.unitofmeas, accesreq1.qty,accesreq1.stylename,;
accesreq1.buordno,accesreq1.buname from accesreq inner join accesreq1;
on accesreq.reqno=accesreq1.reqno into cursor xor1 readwrite;
where accesreq.reqno=thisform.pageframe1.page1.combo1.Value
ALTER TABLE xor ADD COLUMN flag l
REPLACE all flag WITH .t. for !EOF()
thisform.pageframe1.page2.grid1.recordsource="sele flag,stylename,buname,buordno,itemcode,itemname,size,unitofmeas,qty from xor into cursor x"
thisform.pageframe1.page2.Refresh()
thisform.pageframe1.ActivePage=2
WITH thisform.pageframe1.page2
SELECT xor
.text1.value=xor1.reqno
.text2.value=xor1.department
.text3.value=xor1.unit
.text4.value=xor1.dyissparty
.text5.value=xor1.reqname
.text6.value=DATE()
.text7.value=xor1.companyname
ENDWITH
The Error is generated at line "ALTER TABLE xor ADD COLUMN flag l". Now will any one pls suggest me why its happening and what is the solution for it.
Waiting for replies.
Thanx & Regards
Chandan