populate the list dynamically [message #579811] |
Fri, 15 March 2013 10:56 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
irfankundi786@yahoo.com
Messages: 269 Registered: February 2009 Location: pakistan
|
Senior Member |
|
|
i want to create the list item dynamically on the when new form instance this is the code....
group_id := create_group_from_query('lst','select (imt.item_id), to_char(imt.item_code, from items_mt imt');
v_num := Populate_group(group_id);
populate_list(v_num,group_id);
but the list is not the populate...please help...
|
|
|
|
|
|
Re: populate the list dynamically [message #579867 is a reply to message #579820] |
Sat, 16 March 2013 02:57 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
irfankundi786@yahoo.com
Messages: 269 Registered: February 2009 Location: pakistan
|
Senior Member |
|
|
declare
group_id recordgroup;
v_num number;
begin
group_id := create_group_from_query('lst','select (imt.item_id), to_char(imt.item_code) from items_mt imt');
v_num := Populate_group(group_id);
populate_list('lst_product',v_num);
end;
this is actual code...
please help me to populate the list item...
my first field imt.item_id is number and item_code is character field..........
|
|
|
|
Re: populate the list dynamically [message #579871 is a reply to message #579869] |
Sat, 16 March 2013 05:15 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
chrisvelarde
Messages: 5 Registered: March 2009
|
Junior Member |
|
|
You have populated the data you need. The next step is displaying them correctly.
First define a node collection.
Later you can define the nodes that are contained in the node collection, this can be made dynamically
using a while statement.
|
|
|
|
Re: populate the list dynamically [message #579890 is a reply to message #579884] |
Sat, 16 March 2013 10:36 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
irfankundi786@yahoo.com
Messages: 269 Registered: February 2009 Location: pakistan
|
Senior Member |
|
|
i am not using hierarchical tree i am trying to create list item which is populated dynamically having two column one for the
value stored in database and one for the displaying the label.
please anyone which can correct the code i have paste.
error is that that list item is not populating.......
please give me suggestion for the list item not for the tree..
|
|
|
Re: populate the list dynamically [message #579893 is a reply to message #579890] |
Sat, 16 March 2013 16:42 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
chrisvelarde
Messages: 5 Registered: March 2009
|
Junior Member |
|
|
I'm sorry, my fault. Didn't personally work on a list.
Nevertheless I assume there has to be an analogy between both OCX objects.
In the TreeView you use for example the command release_obj(hNode); in order to display a previously defined object
in the OCX container. Perhaps there is a similar function/procedure for the list.
It also isn't clear which EVENT triggers the code?
A first approach may be to know exactly which packages are being used by the list and have to be present.
The information you find in the Internet about this topic is very scarce. Had serious trouble figuring out
the architecture for the tree myself. A step by step analysis helped me to put all the missing parts together
until everything became to make sense.
Perhaps you have a data type problem. Your query returns two values and maybe you have to populate
every column in the list separately? Try displaying first only one column and one line to figure out
the logic behind it.
|
|
|
|
|
Re: populate the list dynamically [message #579913 is a reply to message #579893] |
Sun, 17 March 2013 08:49 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
cookiemonster
Messages: 13937 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
chrisvelarde wrote on Sat, 16 March 2013 21:42
In the TreeView you use for example the command release_obj(hNode); in order to display a previously defined object
in the OCX container. Perhaps there is a similar function/procedure for the list.
No there isn't.
chrisvelarde wrote on Sat, 16 March 2013 21:42
It also isn't clear which EVENT triggers the code?
That is a good question
chrisvelarde wrote on Sat, 16 March 2013 21:42
A first approach may be to know exactly which packages are being used by the list and have to be present.
None.
chrisvelarde wrote on Sat, 16 March 2013 21:42
The information you find in the Internet about this topic is very scarce.
Probably because the form builder help topics on the subject are comprehensive.
chrisvelarde wrote on Sat, 16 March 2013 21:42
Your query returns two values and maybe you have to populate every column in the list separately?
No.
|
|
|
Re: populate the list dynamically [message #579966 is a reply to message #579913] |
Mon, 18 March 2013 07:15 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](http://www.gravatar.com/avatar/1229663c86eb1a441385fe710cd9116e?s=64&d=mm&r=g) |
mughals_king
Messages: 392 Registered: January 2012 Location: pakistan
|
Senior Member |
|
|
Dear @Ranamirfan hope this time u would get something here is some example or otherwise
tell me i shall send u .FMB file
DECLARE
rg_name VARCHAR2(40) := 'Salary_Range';
rg_id RecordGroup;
errcode NUMBER;
BEGIN
rg_id := Find_Group( rg_name );
IF NOT Id_Null(rg_id) THEN
Delete_Group( rg_id );
END IF;
IF :RDG_VAL = 'E'
THEN
rg_id := Create_Group_From_Query( rg_name, 'SELECT ename ename1,'
||'ename ename2 '
||'FROM EMP '
||'ORDER BY 1');
ELSE
rg_id := Create_Group_From_Query( rg_name, 'SELECT dname dname1,'
||'dname dname2 '
||'FROM dept '
||'ORDER BY 1');
END IF;
errcode := Populate_Group( rg_id );
populate_List('TEST_LIST',rg_id);
END;
mughal
[Updated on: Mon, 18 March 2013 07:16] Report message to a moderator
|
|
|
|