I have a form(whrec000a) based on a set(whtranset0)
The set has 2 tables.(header and transactions detail)
I also have another table(inventory) that is not in the set but I have showing on the screen.(3 tables on one screen)
the following script in on the action of a browse on row doubleclick of the inventory table.
It works ok dow to step 2.I have noted where I need help to activate the transactions table to enter a new record.
Thanks
Charlie Crimmel
''XBasic
trace.clear()
'code = UI_ATTENTION_SYMBOL
'ui_msg_box("","testing on row change",code)
dim global itemno as c
dim global descript as c
dim global measure as c
' *********** step 1 post variables ************
trace.writeln("*********** step 1 post variables ************")
tbl=table.current()
table_name = tbl.name_get()
trace.writeln("Current table is now "+table_name)
trace.writeln("-------------------------------")
trace.writeln("OnRow Double Click")
trace.writeln("-------------------------------")
var->itemno2=item->itemno
trace.writeln("Variables:itemno "+itemno2)
var->descript2=item->descript
trace.writeln("Variables:itemdesc "+descript2)
var->measure2=item->measure
trace.writeln("Variables:measure "+measure2)
trace.writeln("-------------------------------")
' *********** step 2 Change table and enter new record ************
trace.writeln("Begin step 2")
trace.writeln("*******step 2 Change table and enter new record*******")
'works ok to this point
' *********** Need Help Here **************************
' How do I re-activate the whtransaction table to post new records?
' It is in a set called whtransset0
' as the secon table.
' I have tried tbl=table.current(2) and also
' tbl=table.("whtransaction")
' ************************************************
'table_name = tbl.name_get()
trace.writeln("Current table is now "+table_name)
trace.writeln("-------------------------------")
trace.writeln("enter table_begin() ")
':frmwhrec000a.itemno=var->itemno
tbl.itemno=var->itemno
tbl.enter_end(.t.)
trace.writeln("New record Entered")
trace.writeln("-------------------------------")
end
The set has 2 tables.(header and transactions detail)
I also have another table(inventory) that is not in the set but I have showing on the screen.(3 tables on one screen)
the following script in on the action of a browse on row doubleclick of the inventory table.
It works ok dow to step 2.I have noted where I need help to activate the transactions table to enter a new record.
Thanks
Charlie Crimmel
''XBasic
trace.clear()
'code = UI_ATTENTION_SYMBOL
'ui_msg_box("","testing on row change",code)
dim global itemno as c
dim global descript as c
dim global measure as c
' *********** step 1 post variables ************
trace.writeln("*********** step 1 post variables ************")
tbl=table.current()
table_name = tbl.name_get()
trace.writeln("Current table is now "+table_name)
trace.writeln("-------------------------------")
trace.writeln("OnRow Double Click")
trace.writeln("-------------------------------")
var->itemno2=item->itemno
trace.writeln("Variables:itemno "+itemno2)
var->descript2=item->descript
trace.writeln("Variables:itemdesc "+descript2)
var->measure2=item->measure
trace.writeln("Variables:measure "+measure2)
trace.writeln("-------------------------------")
' *********** step 2 Change table and enter new record ************
trace.writeln("Begin step 2")
trace.writeln("*******step 2 Change table and enter new record*******")
'works ok to this point
' *********** Need Help Here **************************
' How do I re-activate the whtransaction table to post new records?
' It is in a set called whtransset0
' as the secon table.
' I have tried tbl=table.current(2) and also
' tbl=table.("whtransaction")
' ************************************************
'table_name = tbl.name_get()
trace.writeln("Current table is now "+table_name)
trace.writeln("-------------------------------")
trace.writeln("enter table_begin() ")
':frmwhrec000a.itemno=var->itemno
tbl.itemno=var->itemno
tbl.enter_end(.t.)
trace.writeln("New record Entered")
trace.writeln("-------------------------------")
end
Comment