Home » Developer & Programmer » Forms » Treeview with images and checkboxes in forms with OLE-Container (Oracle Forms 6i)
|
|
|
|
|
Re: Treeview with images and checkboxes in forms with OLE-Container [message #409337 is a reply to message #409326] |
Mon, 22 June 2009 03:39 ![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) |
snao00
Messages: 14 Registered: June 2009 Location: Magdeburgo, Alemania
|
Junior Member |
![snao00@gmail.com](/forum/theme/orafaq/images/google.png) ![snao00](/forum/theme/orafaq/images/skype.png)
|
|
i already tried this:
PROCEDURE /* NodeCheck */ EVENT6(interface OleObj, Node IN MSComctlLib_CONSTANTS.Node) IS
x_nodes MSComctlLib_CONSTANTS.INodes;
x_node MSComctlLib_CONSTANTS.INode;
x_node2 MSComctlLib_CONSTANTS.INode;
BEGIN
if MSComctlLib_INode.checked(x_node) = 0
then
MSComctlLib_INode.checked(x_node2,0);
else
MSComctlLib_INode.checked(x_node2,0);
end if;
END;
what i use to create the child-nodes is in when-new-forms instance and is:
for k in 1..10 loop
x_node2 := MSCOMCTLLIB_iNodes.ole_add
(x_nodes,to_variant('A1'),to_variant(4),
to_variant('B' || '' || LTRIM(k)),
to_variant('Teil_' || '' || LTRIM(k)),
to_variant(1),to_variant(2));
MSComctlLib_INode.bold(x_node2,1);
end loop; [EDITED by DJM: applied [code] tags]
[Updated on: Tue, 23 June 2009 01:17] by Moderator Report message to a moderator
|
|
|
Re: Treeview with images and checkboxes in forms with OLE-Container [message #409345 is a reply to message #409337] |
Mon, 22 June 2009 04:19 ![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) |
snao00
Messages: 14 Registered: June 2009 Location: Magdeburgo, Alemania
|
Junior Member |
![snao00@gmail.com](/forum/theme/orafaq/images/google.png) ![snao00](/forum/theme/orafaq/images/skype.png)
|
|
sorry for replying in three different coments.
I cant with the drag and drop i already read what you have post me but that have nothing to do with what im doing.
and i already searched in the old pages and i couldnt find something that can help me.
this is my complete code:
Sorry but all the explanations are in german because im doing it in Germany.
-- Dieses Programm ermöglich der Aufbau eines TreeView
-- mit den Eigenschaften "Drag and Drop", "Checkboxes", "ImageList"
-- ohne die Nutzung einer Datenbank.
-- Deklaration der Variabeln
declare
-- Variablen für die Aufbau des Baums
x_tree oleobj;
x_nodes MSComctlLib_CONSTANTS.INodes;
x_node MSComctlLib_CONSTANTS.INode;
x_node2 MSComctlLib_CONSTANTS.INode;
-- Variable für die ImageList
x_imli Oleobj;
begin
-- Diese Labeln sind für die temporale Objekte
:Label1 := 'Knoten';
:Label2 := 'Zielposition';
:Label3 := 'Position im X';
:Label4 := 'Position im Y';
-- Der Abruf des Interfaces des OcxObjektes
x_tree:= GET_INTERFACE_POINTER ('BL_TREE.TREE');
-- ImageList
-- Hier setzen wir das ImageList-Objekt in x_imli
x_imli:= GET_INTERFACE_POINTER ('BL_TREE.IMAGES');
-- Wir müssen dieses Objekt in unseren Baum einsetzen.
MSCOMCTLLIB_ITREEVIEW.IMAGELIST(x_tree,x_imli);
-- Die Einsetzung der Eingenschaften für die Expandierung und das Unterstreichen des Knotens
MSCOMCTLLIB_ITREEVIEW.Style(x_tree,7);
-- Die Einsetzung der Eingenschaften für die Editierung des Textes der Knoten
MSCOMCTLLIB_ITREEVIEW.StartLabelEdit(x_tree);
MSCOMCTLLIB_ITREEVIEW.LabelEdit(x_tree,0);
-- x_nodes haben die Eigenschaften aus den Knoten
x_nodes:= MSComctlLib_ITreeView.Nodes(x_tree);
-- Um die Knoten zu aktualizieren
MSComctlLib_INodes.clear(x_nodes);
-- Checkbox Eigenschaft einsetzen
MSComctlLib_ITreeView.Checkboxes(x_tree, 1);
-- Add NODES, jeder Knoten muss verschiedene "Key" haben
-- und sollen nicht mit numeriches- sondern mit alpha Schriftzeichen beginnen.
/*
Jeder Teil ist:
x_node := MSCOMCTLLIB_iNodes.ole_add
(Interface => x_nodes,
Angehörige => olevar_empty,
Verbindung => to_variant(1), -> 1 Vater, 4 Kind
Schlüssel => to_variant('A1'),
Text => to_variant('Auftrag');
Image => to_variant(3)); <- # index in unserem ImageList-Objekt
Image2 => to_variant(3)); <- # index in unserem ImageList-Objekt
*/
-- Das Einfügen des Vaterknotens
x_node := MSCOMCTLLIB_iNodes.ole_add(x_nodes, OleVar_empty, to_variant(1),
to_variant('A1'), to_variant('Auftrag'),to_variant(3));
MSComctlLib_INode.bold(x_node,1);
MSComctlLib_INode.checked(x_node,1);
-- Das Einfügen der Kinderknoten
-- K ist Anzahl von Knoten
-- Achtung: es ist möglich bis zum 65,534 Knoten in das Objekt einfügen
-- Dieses Einfügen dauert 6 Minuten und 55 Sekunden.
for k in 1..10 loop
x_node2 := MSCOMCTLLIB_iNodes.ole_add(x_nodes,to_variant('A1'),to_variant(4),
to_variant('B' || '' || LTRIM(k)),
to_variant('Teil_' || '' || LTRIM(k)),
to_variant(1),to_variant(2));
MSComctlLib_INode.bold(x_node2,1);
end loop;
-- Expanded Eigenschaft für den Vaterknoten und die Kinderknoten
MSComctlLib_INode.expanded(x_node,0);
-- MSComctlLib_INode.expanded(x_node2,0);
-- Selection Eigenschaft
MSComctlLib_ITreeView.HotTracking(x_tree, 1);
-- Drag und Drop Verfahren
MSComctlLib_ITreeView.OLEDragMode(x_tree, 1); -- 1-Automatic
MSComctlLib_ITreeView.OLEDropMode(x_tree, 1); -- 1-Manual
end;
and the the other things that im doing are in the events of the treeview but there are also efects but i cant find it im already looking for it just like in visual there is a .move hier should be a move or something like that that can help.
these are all the events that i can use:
PACKAGE MSComctlLib_TreeCtrl_2_EVENTS IS
-- The Events Package:
PROCEDURE /* BeforeLabelEdit */ EVENT1(interface OleObj, Cancel IN NUMBER);
PROCEDURE /* AfterLabelEdit */ EVENT2(interface OleObj, Cancel IN NUMBER, NewString IN VARCHAR2);
PROCEDURE /* Collapse */ EVENT3(interface OleObj, Node IN MSComctlLib_CONSTANTS.Node);
PROCEDURE /* Expand */ EVENT4(interface OleObj, Node IN MSComctlLib_CONSTANTS.Node);
PROCEDURE /* NodeClick */ EVENT5(interface OleObj, Node IN MSComctlLib_CONSTANTS.Node);
PROCEDURE /* KeyDown */ EVENT4294966694(interface OleObj, KeyCode IN NUMBER, Shift IN NUMBER);
PROCEDURE /* KeyUp */ EVENT4294966692(interface OleObj, KeyCode IN NUMBER, Shift IN NUMBER);
PROCEDURE /* KeyPress */ EVENT4294966693(interface OleObj, KeyAscii IN NUMBER);
PROCEDURE /* MouseDown */ EVENT4294966691(interface OleObj, Button IN NUMBER, Shift IN NUMBER,
x IN /* stdole_CONSTANTS.OLE_XPOS_PIXELS */ NUMBER, y IN /* stdole_CONSTANTS.OLE_YPOS_PIXELS */ NUMBER);
PROCEDURE /* MouseMove */ EVENT4294966690(interface OleObj, Button IN NUMBER, Shift IN NUMBER,
x IN /* stdole_CONSTANTS.OLE_XPOS_PIXELS */ NUMBER, y IN /* stdole_CONSTANTS.OLE_YPOS_PIXELS */ NUMBER);
PROCEDURE /* MouseUp */ EVENT4294966689(interface OleObj, Button IN NUMBER, Shift IN NUMBER,
x IN /* stdole_CONSTANTS.OLE_XPOS_PIXELS */ NUMBER, y IN /* stdole_CONSTANTS.OLE_YPOS_PIXELS */ NUMBER);
PROCEDURE /* Click */ EVENT4294966696(interface OleObj);
PROCEDURE /* DblClick */ EVENT4294966695(interface OleObj);
PROCEDURE /* NodeCheck */ EVENT6(interface OleObj, Node IN MSComctlLib_CONSTANTS.Node);
PROCEDURE /* OLEStartDrag */ EVENT1550(interface OleObj, Data IN OleVar, AllowedEffects IN NUMBER);
PROCEDURE /* OLEGiveFeedback */ EVENT1551(interface OleObj, Effect IN NUMBER, DefaultCursors IN NUMBER);
PROCEDURE /* OLESetData */ EVENT1552(interface OleObj, Data IN OleVar, DataFormat IN NUMBER);
PROCEDURE /* OLECompleteDrag */ EVENT1553(interface OleObj, Effect IN NUMBER);
PROCEDURE /* OLEDragOver */ EVENT1554(interface OleObj, Data IN OleVar, Effect IN NUMBER,
Button IN NUMBER, Shift IN NUMBER, x IN NUMBER,
y IN NUMBER, State IN NUMBER);
PROCEDURE /* OLEDragDrop */ EVENT1555(interface OleObj, Data IN OleVar, Effect IN NUMBER,
Button IN NUMBER, Shift IN NUMBER, x IN NUMBER,
y IN NUMBER);
END; [EDITED by DJM: applied [code] tags]
[Updated on: Tue, 23 June 2009 01:20] by Moderator Report message to a moderator
|
|
|
|
Re: Treeview with images and checkboxes in forms with OLE-Container [message #409558 is a reply to message #409535] |
Tue, 23 June 2009 02:03 ![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) |
snao00
Messages: 14 Registered: June 2009 Location: Magdeburgo, Alemania
|
Junior Member |
![snao00@gmail.com](/forum/theme/orafaq/images/google.png) ![snao00](/forum/theme/orafaq/images/skype.png)
|
|
Of course that that is the intention but the question is how. all the manuals that i found are about visual basic and such that events i dont have idea how to declare them i cant even do a remove. Also there another but are with built-in-packages and with an Ole-Container is not allowed.
I already wrote some code in these move down and mouse move but with no succes. i still keep trying.
What i say also is this:
Effect IN NUMBER --> this automatic declaration in oledragdrop and other one obvioulsy means that there effects with .move like in visual basic but the help of Oracle Forms 6i doesnt help me at all.
All that i´ve done at this point is not much but i did it alone
and with manuals in visual basic is realy hard.
[Updated on: Tue, 23 June 2009 02:09] Report message to a moderator
|
|
|
|
|
|
Re: Treeview with images and checkboxes in forms with OLE-Container [message #409568 is a reply to message #409567] |
Tue, 23 June 2009 02:25 ![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) |
snao00
Messages: 14 Registered: June 2009 Location: Magdeburgo, Alemania
|
Junior Member |
![snao00@gmail.com](/forum/theme/orafaq/images/google.png) ![snao00](/forum/theme/orafaq/images/skype.png)
|
|
im generating each node with code:
-- Parent node
x_node := MSCOMCTLLIB_iNodes.ole_add(x_nodes, OleVar_empty, to_variant(1),to_variant('A1'),
to_variant('Auftrag'),to_variant(3));
MSComctlLib_INode.bold(x_node,1);
-- Child Nodes
for k in 1..10 loop
x_node2 := MSCOMCTLLIB_iNodes.ole_add(x_nodes,to_variant('A1'),to_variant(4),
to_variant('B' || '' || LTRIM(k)),
to_variant('Teil_' || '' || LTRIM(k)),
to_variant(1),to_variant(2));
MSComctlLib_INode.bold(x_node2,1);
end loop; [EDITED by DJM: applied [code] tags and cut a code line]
[Updated on: Wed, 01 July 2009 19:06] by Moderator Report message to a moderator
|
|
|
|
Re: Treeview with images and checkboxes in forms with OLE-Container [message #409792 is a reply to message #409750] |
Wed, 24 June 2009 01: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) |
snao00
Messages: 14 Registered: June 2009 Location: Magdeburgo, Alemania
|
Junior Member |
![snao00@gmail.com](/forum/theme/orafaq/images/google.png) ![snao00](/forum/theme/orafaq/images/skype.png)
|
|
a move i supposed that would do the effect of moving the node when somebody is dragging over the other nodes. but the problem is that i dont know how to declare such effects and somethings that are very necesary for this drag and drop. the help in Oracle Forms 6i for this Ole-Container with TreeView is not complete. when i say no complete is because there are just basics things like populating the tree and that is already done.
[Updated on: Wed, 24 June 2009 01:43] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Goto Forum:
Current Time: Mon Feb 10 03:16:47 CST 2025
|