?
Solved

Drop & Drag in Forms

Posted on 2002-07-23
2
Medium Priority
?
439 Views
Last Modified: 2012-06-21
I can get the drop & Drag feature to work in forms. Does anyone know if it works on the web I cant seem to get it to work?

0
Comment
Question by:Maritimer
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Author Comment

by:Maritimer
ID: 7172338
Found the answer on the oracle site
0
 
LVL 14

Accepted Solution

by:
leoahmad earned 100 total points
ID: 7173148
Hi Meritimer,

Place some items(like buttons ) on a form and put the following codes at form level triggers:

(1) When-new-form-instance trigger:

DECLARE
D BOOLEAN;
BEGIN
:GLOBAL.D:='FALSE';
END;

(2) When-mouse-down trigger:

DECLARE
I ITEM;
N NUMBER;
BEGIN
:GLOBAL.D:='TRUE';
I:=FIND_ITEM(:SYSTEM.MOUSE_ITEM);
:global.item:=i.id;
EXCEPTION
WHEN OTHERS THEN
MESSAGE('NO ITEM CLICKED');
:GLOBAL.D:='FALSE';
END;

(3) when-mouse-up trigger:

:GLOBAL.D:='FALSE';

(4) when-mouse-move trigger:

declare
i item;
p number;
P1 NUMBER;
begin
if :global.d='TRUE' then
i.id:=to_number(:global.item);
p:=get_item_property(i,x_pos);
set_item_property(i,x_pos,p+:system.mouse_x_pos);
p1:=get_item_property(i,y_pos);
set_item_property(i,y_pos,p1+:system.mouse_y_pos);
else
null;
end if;
end;

After writing the code run the form and select any item on the form click on it and now you can easily drag and drop this item.
These trigger impliment the drag and drop facility.
You can use it at any form.




0

Featured Post

Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I remember the day when someone asked me to create a user for an application developement. The user should be able to create views and materialized views and, so, I used the following syntax: (CODE) This way, I guessed, I would ensure that useā€¦
Shell script to create broker configuration file using current broker Configuration, solely for purpose of backup on Linux. Script may need to be modified depending on OS-installation. Please deploy and verify the script in a test environment.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question