Suppose you have two T-List items in form and you want  to shift element values from one list to another in Oracle Forms, here is the example given below for the same. Create two buttons also between list items as shown in picture in the bottom of this blog. Create one button with label ">" and another with label "<".

When-button-pressed trigger code for button with label ">":

declare
    n number;
    vval varchar2(100);
begin
    --- replace rightsidelist with your list name placed on right side
    --- replace leftsidelist with your list name placed at left side
      n := get_list_element_count('rightsidelist');
      add_list_element('rightsidelist', n + 1, :leftsidelist, :leftsidelist);
      --- delete element
      n := get_list_element_count('leftsidelist');
      for i in 1..n loop
            vval := get_list_element_value('leftsidelist',i);
           if vval = :leftsidelist then
                   delete_list_element('leftsidelist',i);
           end if;
      end loop;
end;

When-button-pressed trigger for button with label "<":

declare
    n number;
    vval varchar2(100);
begin
      n := get_list_element_count('leftsidelist');
      add_list_element('leftsidelist', n + 1, :rightsidelist, :rightsidelist);      
      
      --- delete element
      n := get_list_element_count('rightsidelist');
      for i in 1..n loop
            vval := get_list_element_value('rightsidelist',i);
           if vval = :rigtsidelist then
                   delete_list_element('rightsidelist',i);
           end if;
      end loop;
end;

See also: Create List Item In Oracle Forms 

 

Shifting List Item Values From One List To Another In Oracle Forms的更多相关文章

  1. Adding List Item Element At Runtime In Oracle Forms

    Add combo list / drop down list item element at runtime in Oracle forms.SyntaxPROCEDURE ADD_LIST_ELE ...

  2. Populating Tree Item With Record Group In Oracle Forms

    The below plsql program unit could be used in a WHEN-NEW-FORM-INSTANCE trigger to initially populate ...

  3. Determining Current Block and Current Item in Oracle Forms

    SYSTEM.CURSOR_BLOCK Determining current block in Oracle Forms Using SYSTEM.CURSOR_BLOCK system varia ...

  4. Populate A List Item With Record Group In Oracle Forms Using Populate_List And Create_Group_From_Query Command

    Example is given below to Populate a List Item in Oracle Forms using Create_Group_From_Query , Popul ...

  5. An Example Of Validating Text Item In Oracle Forms Using When-Validate-Item Trigger

    Example is given below to validate a Text Item in Oracle Forms with specific rules condition which c ...

  6. Highlighting Text Item On Entry In Oracle Forms

    Highlight a Text Item in Oracle Forms With Visual Attribute It is very necessary to highlight the cu ...

  7. Change An Item Property Using Set_Item_Property In Oracle Forms

    Set_Item_Property is used to change an object's settings at run time. Note that in some cases you ca ...

  8. Display LOV (List Of Values) Using Show_Lov In Oracle Forms

    Show_Lov Function is used to display list of values (LOV) in Oracle Forms. It returns TRUE if the us ...

  9. Populating Display Item Value On Query In Oracle Forms

    Write Post-Query trigger for the block you want to fetch the field value for display item.ExampleBeg ...

随机推荐

  1. VMware搭建 sql server2012集群加节点 KB953748

    --node4加入节点前 将共享磁盘挂载到node4,仅测试验证磁盘挂载,否则会导致整个集群磁盘offline切换 --node4 加入集群报错,无法访问计算机“node4” 0.public网卡勾选 ...

  2. intall vs code in elementary os

    Open Terminal & Type Install Ubuntu Makesudo apt-get install ubuntu-make Microsoft Visual Studio ...

  3. oracle的面试问题

    1. Oracle跟SQL Server 2005的区别? 宏观上: 1). 最大的区别在于平台,oracle可以运行在不同的平台上,sql server只能运行在windows平台上,由于windo ...

  4. 【python cookbook】【字符串与文本】2.在字符串的开头或结尾处做文本匹配

    问题:在字符串的开头或结尾处按照指定的文本模式做检查,例如检查文件的扩展名.URL协议类型等: 解决方法:使用str.startswith()和str.endswith()方法 >>> ...

  5. Yeoman

    安装Yeoman之前,确认安装好Node.js和npm. sudo npm install --global yo 然后查看软件版本 yo --version && bower --v ...

  6. PHP将多张小图拼接成一张大图

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> < ...

  7. poj-3259-wormholes-spfa-判负环

    题意:N个顶点, M条双向边, W条权值为负的单向边.求是否存在负环. 思路:首先你要懂bellman-ford或spfa..这是基础的spfa判断是否存在负环的题,存在负环的节点会重复入队(因为最短 ...

  8. 杭电1005-Number Sequence

    问题描述 A number sequence is defined as follows:f(1) = 1, f(2) = 1, f(n) = (A * f(n - 1) + B * f(n - 2) ...

  9. P问题、NP问题和NPC问题

    P问题.NP问题和NPC问题 这或许是众多OIer最大的误区之一.    你会经常看到网上出现“这怎么做,这不是NP问题吗”.“这个只有搜了,这已经被证明是NP问题了”之类的话.你要知道,大多数人此时 ...

  10. c#对话框

    OpenFileDialog open = new OpenFileDialog();//创建对话框 open.InitialDirectory = @"C:\Documents and S ...