Студопедия
Случайная страница | ТОМ-1 | ТОМ-2 | ТОМ-3
АрхитектураБиологияГеографияДругоеИностранные языки
ИнформатикаИсторияКультураЛитератураМатематика
МедицинаМеханикаОбразованиеОхрана трудаПедагогика
ПолитикаПравоПрограммированиеПсихологияРелигия
СоциологияСпортСтроительствоФизикаФилософия
ФинансыХимияЭкологияЭкономикаЭлектроника

Adding a dialog: Part I

Basic Functions : FIXED | Paste Special II - Removing formulae | Secret StarWars games | Using Names as constants | Listing Cell Notes | Checkerboard shading | Using Pop Up Notes in Cells | Formatting ratios | Filling a multiplication chart | Spelling out numbers |


Читайте также:
  1. Adding a background graphic
  2. Adding a dialog: Part II

September 8th, 2005

In this multi-part article, we will be adding a dialog in a modification of our TextUtils feature. The dialog will permit the user - via radio buttons - to choose which of our functions UpperC, LowerC, or ProperC will be applied to the selected cells.

The dialog editor is invoked through the Macro Organizer. First, select Tools - Macros - Organize Macros - OpenOffice.org Basic as shown below

This opens the OpenOffice.org Basic Macros dialog - below. Now open the OpenOffice.org Basic Macro Organizer dialog as shown below.

Now select the Dialogs tab and with the Standard LIbrary of the open document selected, create a new dialog by clicking New

We rename the new dialog from the default to TextUtils - below.

We now go into the Dialog editor by clicking Edit as shown below.

The initial view of the Dialog Editor with the toolbox on the left and a ‘blank’ dialog on the right.

The dialog components (or controls) are added by first selecting the desired component type from the floating toolbox. As you move the cursor over the toolbox, each component identifies itself. For our particular example, we want to add some option buttons (or radio buttons) as we only want to have one selected at a time. Left-click to activate a component as shown below. Not the white border around the selected component.

Moving the cursor into the dialog, you should see crosshairs (below)

Left-click and drag to define the outline of the new control.

Releaing the mouse, a new default instantiation of the control appears. The green boxes indicate the component is selected and ready for editing

With the cursor inside the boundary of the new component, right-click and select Properties as shown below.

The Properties dialog for each component has two tabs. We first focus on the position and appearance of the control while assigning it a meaningful identifier. We do this in the General tab. In the next part of the tutorial, we will be integrating the dialog and it’s controls with the macros we have created. This will involve the Events tab.

Here is the partially completed dialog - with three radio buttons and two command buttons. It may look complete - but it is not yet integrated into the document.

To be continued….

 

-----------------------------------------------------------------------------------------------------------


Дата добавления: 2015-08-03; просмотров: 49 | Нарушение авторских прав


<== предыдущая страница | следующая страница ==>
Macros: Text Utilities Part I| Adding a dialog: Part II

mybiblioteka.su - 2015-2024 год. (0.006 сек.)