Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DataStore

Status
Not open for further replies.

magni

Programmer
Oct 11, 2007
12
0
0
CA
Hi
I have a dw called dw_search that is working fine and displaying all the products. I have a size button on that dw_search. I created a datastore called dw_sizestore. Also I created another window called dw_size. In my datastore I store size table, product table and calss table.
here my question is if i click on that size button, how can I display all the size from the datastore?
How can I get data from Data store .

string ls_tmp, ls_tmp1, ls_find
long ll_rowsw, ll_rowdw
dw_size.Reset()
dw_size.SetRedraw(true)
ll_rowdw = dw_size.InsertRow(0)
ll_rowsw = dw_search.getrow()
ls_find = "product_id = '" dw_search.GetItemString(ll_rowsw, 'product_id') + "'"
ll_rowdw=dw_sizestore.fn_action_find(ls_find,ll_rowdw, 0, ::mds.dw.cs_FIND_SET)
do while ll_rowdw > 0
ls_tmp=dw_sizestore.fn_get_string( "size_id")
ls_tmp1=sizestore.fn_get_string("size_descr")
dw_size.setitem(ll_rowdw, "size_id", ls_tmp)
dw_size.setitem(ll_rowdw, "descr_2", ls_tmp1)
ll_rowdw ++
if ll_rowdw >dw_sizestore.il_rows then
ll_rowdw= 0
else
ll_rowdw= dw_sizestore.fn_action_find(ls_find, ll_rowdw, 0, ::mds.dw.cs_FIND_SET)
end if
dw_sizestore.ids_recordset.Sort()
loop



Thank you.
 
Hi,

You can get values from datastore as you get value from datawindow. e.g.

variable = datastore.object.column [index]

or
variable = datastore.getitemString (index,"column_name")
for further details please go through the help of getitemString or getitemNumber or getitemDate etc.

Get value from datastore and process it.

Regards,
Abhijit.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top