Setting the size of the trees

Hello

Is it possible to programmatically set the width and height of a hierarchical tree, based on the values containing in it?
As if there are only 2 nodes in the tree, the size should be just enough to show the two nodes.
If it has the largest number of nodes, the size should change accordingly
Is this possible? (I use forms6i)

Pls help
Thank you

Adkins,

You can get the number of nodes of GET_TREE_PROPERTY integrated and can adjust its height by SET_ITEM_PROPERTY integrated. But it should be in the size of the canvas, otherwise it will give an error.

Check the code below.

DECLARE
   HTree        ITEM;
   Num_Count    NUMBER;
   Num_Height   NUMBER;
   Num_Y_Pos    NUMBER;
   Num_Required NUMBER;
BEGIN
     HTree        := FIND_ITEM('.');
     Num_Count    := Ftree.GET_TREE_PROPERTY(HTree, FTree.NODE_COUNT);
     Num_Height   := GET_CANVAS_PROPERTY('', HEIGHT);
     Num_Y_Pos    := GET_ITEM_PROPERTY('.', Y_POS);
     Num_Required := Num_Count * 22;
     Num_Height   := Num_Height - Num_Y_Pos;
     IF Num_Required > (Num_Height) THEN
          SET_ITEM_PROPERTY('.', HEIGHT, Num_Height);
     ELSE
          SET_ITEM_PROPERTY('.', HEIGHT, Num_Required);
     END IF;
END;

I hope this helps.

Kind regards

Manu.

If my answer or the answer to another person has been useful or appropriate, please mark accordingly

Tags: Oracle Development

Similar Questions

  • How to set programmatically the ' input length Max ' of a cell of the tree

    I want to specify a maximum length of N_MAX for names of cell of a tree, so that when the user press the F2 key to rename, it has failed to enter more characters N_MAX.

    For existing items in the file of the uir, I am able to get this behavior by setting the tree Edit > edit columns/cells > change cell > entry length Max to 5 (see attached img03.png).

    When the user tries to rename this article, he has failed to enter more than 5 characters (see attached img02.png).

    But how to set this attribute for items added programmatically (for example, through InsertTreeItem ()).

    I was not able to find the right attribute, because the attribute of cells ATTR_LABEL_TEXT_LENGTH (which seems more or less what I'm looking for) is "not definable.

    You have found an omission in documentation. You can use ATTR_MAX_ENTRY_LENGTH and ATTR_MAX_ENTRY_CHARS with SetTreeCellAttribute and SetTreeItemAttribute to set the max entry for a cell of the tree.

    Please report to us this and sorry for the inconvenience.

  • Setting the default size of the popup window

    I need a way to set the default size of the popup window on a specific area or all areas (whichever is easier). There is a particular site that pulls up a PDF in a pop-up window, and always default to a small window, but I need full screen. Apart from the obvious 'simply click on the button full screen every time ", can someone offer me some suggestions? If it were me, I'd just hit the button fullscreen, but I'm trying to set it up for some end-users rather capricious. The device in question (if important) is a Tablet from Dell XPS 18, and the version of Firefox is 24.0, just installed about twenty minutes ago. Forums for research, the only thing I found remotely close to what I'm looking for is to force the popup to allow resizing; This isn't what I need; the pop-up window already allows resizing. I need a way to automatically open it full screen. Thanks in advance for your help.

    Where the tab setting you are interested in I mentioned, the method to define who is in this previous post: https://support.mozilla.org/en-US/questions/968159#answer-469644

  • How to get to 'see' to be able to set the font size? Too small, can't read, especially in Facebook.

    Suddenly, it seems that the police got so small, that I can hardly read it. I have good eyesight and a 21 or 22 "screen. But Firefox has only a single drop-down list, not others he used to have. I need to be able to define the size of the content on the screen. Help! Thank you!

    To the menu 'View' try to press 'Alt' + 'V' on the keyboard.

    To set the default zoom: "Ctrl" + "0" (zero)

    To display the menus again, right-click on the left end of the address bar (where there is an icon of the current web page) and select "Menu Bar".

  • Set the size of fixed table

    Hello. I am developing a VI to a FPGA target and I'm trying to make sure who is using the VI can specify the size of an array of input when they instantiate (such as by the presence of an entry to the VI who said "maximum table size" or something). So far, it seems that the only way to do something like this is to go into the VI himself and manually set the size of table for each entry in the table for the VI (open the VI, do a right-click on each input array, select 'Set the size Dimension', choose 'fixed', set number of items). I would like to have a point where I can set the size of all tables at once (as in my case, they are all the same size) and let the person using the VI set it to the right size for which application they use it for (to be clear, let's say I have two uses for this VI and in one case (, I have a table of entry of size 100 and other use of size 1000, I would like to be able to put these in some way rather than do it through the dialog box). Thank you.

    It's a little more work, but it could be a case of good use for a memory block on the FPGA.  Make it bigger you wait, you need, and then store the actual number of items somewhere.  This will allow you to vary the amount of data without consuming large amounts of FPGA resources on an oversized table.

  • How to set the size of the frame in the controls of decoration

    Hello

    I paint frames or boxes using the templates in the control of "Décorations" in labview.

    Is there another way to set the size of the frames or boxes rather than drag? also, how can I change the color of the borders?

    Thank you

    Joyce

    Select the item.  Click the resize objects in the toolbar.  Choose the last of them, which shows a resizing in a speech bubble.  Now, a dialog box appears that allows you to set the height and width.

    For something of color, Shift right click to bring up the box tool.  Take the brush.  Click on the thing you want to change for example from the border.  It could now be the wrong color, do a right click so that brings up the color picker.  Now, select the color you want in fact.  If you want something to be transparent, choose the T in the upper right of the color dialog box.

  • Programmatically set the size of a table control (not the number of col and lines)

    Hi all

    I am trying to create a little VI, in which the user selects the number of columns and rows in a table, and after clicking on a button 'OK', the table control is displayed in the control panel (to be filled in by the user). To do this, I use the nodes property to the number of columns and lines. I have no problem with that.

    However, I want to "limit" the size of the control table (control of himself, not the dimensions of the table) and make use of vertical and horizontal table, the scroll bars. I want to avoid it is that passes type 100 user and 100 lines and appears a huge table control.

    I could tho this by using an array instead of an array, via the node property "size", but I would use an insead table a table.

    Thank you very much

    Daniel

    With a table control, you cannot set the display size to be anything other than a multiple of a complete cell.

    If you are limited to a number of lines and columns.  If you want to resize with more control you also need to resize the control within the Bay, accessible via the property 'picture Element '.

    Another option (but seems huge exaggerated) is to place your table in a secondary and set the size of the secondary to the size you need and enable scrollbars for her.  It is not an option that I would choose but if it helps...

    Have it, your description of your user interface sounds not very intuitive.  How the user knows at any time exactly what cell they access if they have to scroll backwards?

  • How to set the position and size of the façade using the FPRunTimePosRunCustom method in a c# application?

    How to set the position and size of the façade using the FPRunTimePosRunCustom method in a c# application?

    I found a solution! -Set the size and position of the façade with the help of the

    File > VI properties > window running Position (in category list) > custom (in position of menu drop-down).

    then just accept the current position and size (leave the boxes checked) or set values you want directly (uncheck the boxes and fill in the numbers), or physically position and size the façade and use, the "set to current location" button and press "set size" current All that is easier for you.

    OK so it does not make use of the method VI Methods (Active X) FPRunTimePosRunCustom ([Position], [Size]) but if labview want to make him difficult to use then other means must be found.

  • Can I set the size of a GUI control in centimeters?

    Hello

    I know I can get the resolution of the monitor and with this set the display size of a control in a graphical interface. However, the actual size (in centimeters) actually depends on the dimensions (in centimetres) of the screen. I can't that programmatically?

    Hello

    I got it on my system (Win7Pro SP1) with a few modifications.

    Attached a small sample project that creates a decoration of size in centimetres: you can use as the basis for your real needs.

    Basically, the atlstr.h is only required for some manipulation which is not necessary (as mentioned by the author of the article, you logged in). In addition, you must include windows.h too for some statements and add setupapi.lib to the project. In addition, I did only minor changes: original lines are commented immediately before the actual run lines.

  • How to set the size of text with the report generator

    Hello.

    I'm trying to set the size of the text with the report generator, but I find that I can't do this. Here is an example of the code that I use. Can someone tell me what I'm doing wrong please?

    Thank you, Alec

    I was generation from a word template.

    I hacked my version of the Toolbox to give me maunal indicator control "model? He had obtained his permenatly self stuck on "T". I exposed this flag outside the API, so I can control under certain weather conditions I may or may not use the model police.

    Does anyone know how to use this toolkit, or I did the right thing?

    Cheers, Alec

  • Set the font size in the generation of explicit report using a model

    Does anyone know how to set the font size using the generation of explicit report with MS Word?  I have trouble getting my 11th column to fit the correct size with the imported data table.  The values end up being off the screen.  Any ideas?

    I suspect that the answer is somewhere within MS Word instead of LabVIEW.  However, I tried it figure out in both and had no luck.  In WORD, I updated all fonts size = 10.  However, the table is imported to the format = 12.  In addition, the table cells are the same size, regardless of the number of columns is imported.

    David

    Just for future visitors to this question are aware, it is a known problem with the generation of report express vi.  There is no solution at this time and the problem will be resolved in future versions of LabVIEW.

  • How to set the size of plot-legend with properties?

    Hello

    in the screeenshot I create 10 plots that are displayed in a xy chart.

    According to the number of plots of the legend is updated.

    How can we set the legend is highest of 5 plots and other plots 5 (or more) is visible if you are using the scroll bar?

    Thank you

    Solved.

    Name of the property is under: legend + size + high

  • It is best to set the resolution size and icon of the screen up

    It is best to set the maximum screen resolution before attempting to adjust the size of icons and text on the desktop, notification area, Quick Launch bar and start menu? I know that the icons can be made to the largest and by choosing a lower screen resolution but y at - it a benefit to have the maximum resolution? My view is not too good and I need icons and text to be big enough.

    Hello

    The screen, or the screen resolution, resolution refers to the size of the whole image displayed on your computer screen. Specifically, he refers the number of picture elements, or pixels, which are displayed at the same time. A pixel is the smallest element on your computer screen, the more pixels, the more detailed the picture will be. With fewer pixels, display items will be larger, but there will be less space on the desktop for windows and the programs to run.

    You can visit the link provided below for more information about the screen resolution in Windows XP.

    To change your screen resolution

    http://www.Microsoft.com/resources/documentation/Windows/XP/all/proddocs/en-us/display_change_screen_resolution.mspx?mfr=true

    See also:

    Change your screen resolution

    http://Windows.Microsoft.com/en-us/Windows-XP/help/change-screen-resolution

  • I can adjust the size of the text on the new mail / out, but can't set the size on the mail coming on my screen.

    Problem with the size of the text

    I can adjust the size of the text on the new mail / out, but can't set the size on the mail coming on my screen. Evil in my sight.

    Inhabitant of the desert

    Is this a comment or a question? If a question, care to share with us, what e-mail program you speak?

  • How can I set the default font size and type for the outgoing Hotmail mail?

    How can I set the default font size and type for the outgoing Hotmail mail?

    Hi Dale,

    What is the email client do you use?

    Outlook can be configured per - start Outlook-> Tools-> Options-> mail-> fixed Format and fonts... Select the font and size you need... Click ok on all screens.

    I hope this helps.

Maybe you are looking for