Oracle, Web, Script, SQLserver, Tips & Trick

December 5, 2012

How to automate change x,y position item on database block (oracle developer 6i)

Filed under: dev6i,oracle — sikathabis @ 11:47 am
Tags: ,
For example I want to set x,y position for all fields inside certain canvas

 PROCEDURE SET_POSISI(cvs_name varchar2, block_name varchar2, incx number, incy number) IS
 vName VARCHAR2(50) := block_name;
 vFirstItem VARCHAR2(200);
 vLastItem VARCHAR2(200);
 vCurrItem VARCHAR2(200);
 BEGIN
 GO_BLOCK(vName);
 vFirstItem := vName||'.'||Get_Block_Property(vName,FIRST_ITEM);
 vCurrItem := vFirstItem; 
 vLastItem := vName||'.'||Get_Block_Property(vName,LAST_ITEM);
 <<BLOCK_LIST>>
 WHILE ( vCurrItem != vLastItem ) LOOP
 if GET_ITEM_PROPERTY(vCurrItem,CANVAS_NAME)=cvs_name then
 SET_ITEM_PROPERTY(vcurritem,POSITION, GET_ITEM_PROPERTY(vcurritem,X_POS)+incx, GET_ITEM_PROPERTY(vcurritem,Y_POS)+incy);
 end if;
 vCurrItem := vName||'.'|| Get_Item_Property(vCurrItem,NEXTITEM);
 GO_ITEM(vCurrItem);
 END LOOP BLOCK_LIST;
 END;

If the item including Radio button, you can add this example on BLOCK_LIST looping
 IF vCurrItem =vFirstItem and block_name='CIS_ALAMAT' then
 SET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','DALAM_IBUKOTA',POSITION,
 GET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','DALAM_IBUKOTA',X_POS)+incx,
 GET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','DALAM_IBUKOTA',Y_POS)+incy);
 SET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','LUAR_IBUKOTA',POSITION,
 GET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','LUAR_IBUKOTA',X_POS)+incx,
 GET_RADIO_BUTTON_PROPERTY('CIS_ALAMAT.KD_KOTA2','LUAR_IBUKOTA',Y_POS)+incy);
 end if;

references : https://sites.google.com/site/craigsoraclestuff/orac

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

Teknologi Pendidikan

Just another WordPress.com weblog

KATAKAMI

Jurnalisme Yang Dapat Dipercaya

Tonk Kosonk Baonk Bunyinya

Penampungan Serapah Tanpa Sumpah

Qey050489's Blog

Ayo Bangkit sobat..!!!!!

B. S. Totoraharjo

Orang Bodoh Yang Tak Kunjung Pandai

culturekitchen foodlab

New Food and Art in Yogyakarta

Wahyu Catur Wibowo

Musafir Dunia Maya

SQL.... Still Learning

My Reference on SQL Server

neinframe

Street Photography is like a box of a chocolates, you're never know what you're gonna get - Thomas Leuthard -

Keluarga Andrivito

-- Andrivito's Journal --

DRK™

This site is about Latest NEWS, Articles, Videos, Books, Course, Presentations, Tips & Tricks related to I.T Pro's

Gaurav Saxena

|| तत् त्वम् असि ||

Be a good Moeslim

Menuju Pribadi Muslim Sejati yang Bertaqwa

TuanSUFI

Manajemen Sholat, renungan spiritual, Teknologi Informasi

Pelangi di khatulistiwa....

Mari berbagi kebaikan, pengalaman dan senyum denganku

angkasa13

Ceritanya saya, Pikirannya saya, Hatinya saya

sikathabis

sikathabis semua informasi disini

%d bloggers like this: