How to show or hide the status bar in Microsoft Excel? Excel Status Bar Options What information is displayed on the status bar.

The status bar is located at the bottom of the window. The left side of the status bar displays information about the current document (Fig. 4.3).

Rice. 4.3. Status bar

Description of status bar elements

Element

Description

Current page number

Current section number. The information displayed by this element is only meaningful for sectioned documents

Number of pages from the beginning of the document to the current page (4) and total number of pages in the document (19)

Vertical distance between the cursor and the top edge of the page

Number of lines from the beginning of the page to the cursor

Number of characters from left margin to cursor, including spaces and tabs

In addition, the status bar contains operating mode indicators that inform which mode the editor is currently working in. The black color of the indicators corresponds to the on state of the mode, gray - to the off state.

Purpose of the status bar indicators

Switching modes on/off is carried out using the appropriate commands and settings. In addition, to switch modes, you can double-click the left mouse button on the corresponding indicator.

Context menu

The context menu allows you to perform many of the commands without accessing the menu bar. This tool allows you to speed up many operations. To call the context menu, you need to right-click on the object with which you want to perform an action, or Shift+F10 on keyboard. The content of the menu is determined by what the user is doing at the moment and includes only the most necessary commands.

4.4. Exit ms Word

After completing the current work session, you must exit MS Word. To do this, you can use one of the following methods:

    Select menu File -> Output.

    Select item Close in the system menu of the main MS Word window.

    Place the mouse pointer on the system menu icon in the main MS Word window and double-click the left mouse button.

    Press the button Close in the title bar of the main window.

    Click Alt+F4 on keyboard.

If any of the open windows contains unsaved information, MS Word will prompt you to choose what to do with it. To do this, a dialog box similar to the following will appear on the screen (Fig. 4.4).

Rice. 4.4. Message when closing a document

4.5. Word help system

Like most of the most popular programs, MS Word has context-sensitive help system . This means that you can get help using the tool you are currently working with. The main means of obtaining help information is the menu Reference:

Menu command

Description

Microsoft Word Help

Launches the MS Word help system - depending on the configured parameters

Show assistant

Displays the assistant

What it is?

Allows you to obtain background information about a specific object

Launches Internet Explorer and opens Web pages with the most useful Microsoft information

Find and eliminate

Searches for and automatically fixes errors in the application

About the program

To obtain reference information, you can use it in the following ways:

    Select menu command Help –> Help by Microsoft Word.

    Select menu command Help –> What is it?

    Click F1 at any time during a session with MS Word.

LPTBNOTIFY ptbn =(LPTBNOTIFY) lParam; switch(ptbn->iItem)

lstrcpy(ptbn->pszText, "Help"); ptbn->tbButton.iBitmap = STD_HELP; ptbn->tbButton.idCommand = 11; ptbn->tbButton.fsState = TBSTATE_ENABLED; ptbn->tbButton.fsStyle = TBSTYLE_BUTTON; ptbn->tbButton.dwData = 0; ptbn->tbButton.iString = 10;

return 1; case 1:

lstrcpy(ptbn->pszText, "Delete"); ptbn->tbButton.iBitmap = STD_DELETE; ptbn->tbButton.idCommand = 12; ptbn->tbButton.fsState = TBSTATE_ENABLED; ptbn->tbButton.fsStyle = TBSTYLE_BUTTON; ptbn->tbButton.dwData = 0; ptbn->tbButton.iString = 11;

return 1; default:

If you already have an array of TBBUTTON definitions, then the fastest way to respond to this message is to use the memcpy function to copy TBBUTTON for each message received. Below is how GADGETS does this:

lstrcpy(ptbn->pszText, GetString(ptbn->iItem)); memcpy(&ptbn->tbButton, &tbb, sizeof(TBBUTTON));

Status bar

Status bars are display-only windows, often located at the bottom of the main program window. The most common use of the status bar is that it is used to display detailed descriptions of menu items as the user views them, much like a waiter comments on a particular menu item in a restaurant. When menus are not being viewed, programs often display related information in the status bar. The status of the shift keys is also frequently displayed

- , , . Word processor programs often also display the current page, row, and column.

The status bar has two modes, so it can be used to describe menu items and display other program information. In menu item description mode ("simple mode"), the status bar expands to display a simple line of text. In program status display mode, the status bar displays one or more windows, each of which is called a "part" of the status bar. The specific part of the status bar can be created as a niche with a border that appears raised above the surface of the status bar window, or without a border. In addition, it is possible to add child windows to the status bar, such as a clock or a progress bar. When you switch the status bar from simple mode to program status mode and back again, the status bar keeps one set of hidden windows while another set of visible windows is displayed.

Creating a status bar

The simplest way to create a status bar is to call the CreateStatusWindow function:

hwndStatusBar = CreateStatusWindow(

WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | CCS_BOTTOM, "Ready", hwndParent, 2

This function calls the CreateWindow function, which creates a child window with a parent window hwndParent , with the window text "Ready" (this text appears in the first window of the status bar), an ID of 2. The window style flags are specified in the first parameter.

The table below describes all the style flags that can be used to create a useful status bar. You'll probably want to use the SBARS_SIZEGRIP flag most often because it causes the diagonal hatch to appear in the right corner of the status bar. The remaining style flags modify the initial state and location of the status bar so that it can be located in a location other than the bottom of the parent window's client area, as determined by the CCS_BOTTOM flag.

Style flag

Description

Performance

Displays diagonal hatching in

right corner of the status bar. This area

used to resize the parent

Starting position

Places the status bar at the top

parent window.

Places the status bar at the bottom

parent window (default).

Disables movement relative to the y axis.

Prohibition of automatic

CCS_NOPARENTALIGN

The status bar sets its height

size changes and

(cy). But does not set its location

locations

(x,y) and width (cx). For the corresponding

processing is necessary after creation

send a message about resizing.

Disables all automatic movements and

size changes. This prohibits

the following style flags: CCS_TOP,

CCS_BOTTOM, CCS_NOMOVEY and

CCS_NOPARENTALIGN. You must clearly

set the size and position of the status bar.

Move and resize the status bar

When the status bar's parent window changes size (on receiving a WM_SIZE message), the status bar must take a new position and take on different dimensions to remain at the bottom of the parent window's client area. The toolbar resizes in response to the TB_AUTOSIZE message (see earlier in this chapter). The status bar does not have a similar message. Instead, something like the following is used:

int cxParent = LOWORD(lParam); int cyParent = HIWORD(lParam); int x, y, cx, cy;

// Leave the height of the status bar window unchanged

GetWindowRect(hwndStatusBar, &rWindow); cy = rWindow.bottom - rWindow.top;

y = cyParent - cy; cx = cxParent;

MoveWindow(hwndStatusBar, x, y, cx, cy, TRUE);

This code keeps the status bar's height unchanged and modifies its width and location to fit into the parent window's client area.

Menu browsing support

Users expect Windows programs to display supporting information in the status bar about what function a particular menu item performs. Even the casual Windows user quickly learns that a one-word menu item hides a much broader action. And although experienced users easily understand the meaning of standard menu commands, sometimes they have to spend a lot of effort to understand the meaning of specific menu items for a particular program.

A window menu sends a WM_MENUSELECT message when the user views menu items and a WM_COMMAND message when the user selects a menu item (see Chapter 10). To support the display of supporting information about menu items, the message should be processed

To make it easier to process this message and display text in the status bar, the public controls library supports the MenuHelp function. This function assumes a string table containing the supporting information texts to be displayed, and a data structure that associates menu items with text string IDs from the table. The MenuHelp function is defined as follows:

The first parameter, uMsg, must be equal to WM_MENUSELECT, although the presence of this parameter (and its description in the Win32 documentation) suggests that processing of the WM_COMMAND message was included during the design of the function. The wParam and lParam parameters of the window procedure are passed as the second and third parameters. These three parameters, taken together, describe what part of the menu system the user is viewing, and whether it is a pop-up menu item or a system menu item.

The sixth parameter, hwndStatus, is a handle to the status bar window. The MenuHelp function sends a status bar-specific SB_SIMPLE message to set the status bar to single window (simple) mode and display the corresponding text. Later, when the user stops browsing, the MenuHelp function sends another SB_SIMPLE message to return the status bar to multi-window (non-simple) mode.

The MenuHelp function uses three other parameters—hMainMenu, hInst, and lpwIDs—to determine which line to display when viewing a menu item. The hInst parameter identifies the module, which can be a DLL instance handle or an executable program instance handle, and is the owner of the table containing the menu strings (which you can assume are loaded using the LoadString function).

The way to make the MenuHelp function work correctly is to pass the correct value in the fourth and seventh parameters: hMainMenu and lpwIDs . Setting these values ​​correctly is a bit of a gimmick, as there are three elements to consider: the command menu, the pop-up menu, and the system menu. Another complication is that the Win32 documentation says that lpwIDs is an array that the MenuHelp function searches. Although it makes sense to use an array to store the underlying values ​​of string resources, you will have to do the array parsing yourself since the MenuHelp function does not do this.

Viewing menu items

The MenuHelp function calculates the string resource ID for a menu item by adding the command ID value (derived from the low word of wParam ) to the value referenced by lpwIDs . For example, the following MenuHelp function call displays the string resource number 125 in the status bar:

UINT uiStringBase = 100; WPARAM wParam = 25;

MenuHelp(WM_MENUSELECT, wParam, lParam, NULL, hInst, hwndStatus, &uiStringBase);

As shown in the example, the menu handle hMainMenu can be NULL to display command menu items because the MenuHelp function does not use this value for calculation.

The simplest way to match command menu items and string resources is to give them the same values. This will set the row's base to zero and ignore it.

View pop-up menu items

In the case of a pop-up menu, the MenuHelp function calculates the resource string to display in the status bar by adding the (zero-based) index of the pop-up menu to the value referenced by lpwIDs . For this to work correctly, the fourth parameter of the MenuHelp function, hMainMenu, must be set to the handle of the window's parent popup menu. The structure below provides a convenient way to map menu handles to a string resource base:

typedef struct tagPOPUPSTRING

HMENU hMenu; UINT uiString;

In the GADGETS program, in which three menu items contain pop-up menus, this data structure is defined as follows:

POPUPSTRING popstr;

and is initialized when the status line is created as follows:

GetMenu(hwndParent);

IDS_MAIN_MENU;

GetSubMenu(hMainMenu, 2);

IDS_TOOLBAR_MENU;

GetSubMenu(hMainMenu, 3);

IDS_STATUSBAR_MENU;

When a WM_MENUSELECT message is received, the lParam parameter contains the parent window's menu handle. The MenuHelp function's job of finding the correct string resource requires you to search the array and pass the address as the last parameter to the MenuHelp function. Below is how this is implemented in the GADGETS program:

if((fuFlags & MF_POPUP) &&(!(fuFlags & MF_SYSMENU)))

for(iMenu = 1; iMenu< MAX_MENUS; iMenu++)

For this to work correctly, hMainMenu must be set to the value of the popup menu's parent menu handle. While we were looking at handling our popup menus, we completely forgot about the system menu.

Viewing the System Menu

The MenuHelp function provides a status bar display of help information for the system menu and system menu items. All that is needed for this is the WM_MENUSELECT message parameters wParam and lParam in the same form as for other types of menu items. Additionally, the value of hMainMenu must not be equal to the actual system menu handle; NULL is quite suitable.

Let's now combine all these fragments for menu items, pop-up menus and the system menu. The following code illustrates how the GADGETS program processes the WM_MENUSELECT message to display supporting information in the status bar:

LRESULT Statusbar_MenuSelect(HWND hwnd, WPARAM wParam, LPARAM lParam)

UINT fuFlags =(UINT) HIWORD(wParam); HMENU hMainMenu = NULL;

// Handle non-system popup menus if((fuFlags & MF_POPUP) &&(!(fuFlags & MF_SYSMENU)))

for(iMenu = 1; iMenu< MAX_MENUS; iMenu++)

if((HMENU) lParam == popstr.hMenu)

hMainMenu =(HMENU)lParam; break;

// Display auxiliary information in the status bar

MenuHelp(WM_MENUSELECT, wParam, lParam, hMainMenu, hInst, hwndStatusBar, &((UINT) popstr.hMenu));

Status bar displays various current document information and provides access to some Outlook features.

Customizing the Status Bar is done by right-clicking on it, which will open an additional dialog box:

Formatted page number— shows the number that is on this page.

Chapter— the serial number of the section you are in.

Page number— serial number of the current page and the total number of pages.

Vertical position on page— distance from the top edge where the cursor is located.

Line number— the serial number of the line in which the cursor is positioned.

Column— the serial number of the column in which the cursor is placed.

Number of words— the total number of words in the document.

Spell check— shows whether there are errors in the document.

Language— indicates which keyboard layout is active.

Corrections— shows whether correction mode is enabled.

Caps Lock— indicates whether Caps Lock is enabled.

Replacement— mode change between insertion and replacement.

View mode shortcuts— allow you to switch between reading mode, page layout and web document.

Scale slider— allows you to increase or decrease the text size. You can use the “+” and “-“ buttons, or simply move the slider to the right and left.

Scale— allows you to customize the presentation in more detail.

When you click on the button indicating percentages, a dialog box will open in which the following settings are available:

  • Setting the scale (both specified options and arbitrary);
  • Placement of the window on the screen (by page width, by text width, whole page, several pages);


Status bar contains information about the position of the text cursor in the document and the operating mode of the editor. It is always located at the bottom line of the Word window and is divided into three zones.

On the left is an area indicating the position of the cursor relative to the document. In it:

The following zone displays the cursor position on the current page:

The first two parameters appear in the mode view page layout, third at typing visible text.
The last zone is editing modes. Here:

Enabling/disabling each mode can be done by double-clicking the left mouse button in the area of ​​that mode.

The presence of a status bar is controlled by dialogue Options, which is called from the menu WITH service team P parameters.... Bookmark View This dialog contains a "Window" section with a "status bar" parameter.

34.Microsoft Word word processor – window structure, main toolbars. Why is Microsoft Word a processor and not an editor?

The word processor Microsoft Word 2003 is one of the main components of Microsoft Office 2003. The word processor allows you to create, edit, save, view and print text documents, apply formatting for characters, paragraphs, pages, sections and the document as a whole, assign existing styles for characters, paragraphs, tables and create your own styles. In addition, you can create tables, pictures, charts, formulas, etc. in Word.

Microsoft Office 2003 application windows use standard controls, or graphical interface components, that are combined into larger constructs (menus, toolbars, dialog boxes) that provide the ability to control the application window and change the content and presentation of information displayed in the window. document.

Microsoft Office 2003 uses four types of windows: application windows; document windows; dialog boxes; forms. The document window appears in the application window.

Microsoft Office 2003 applications are controlled using menus and toolbars. Microsoft Office 2003 applications use three types of menus: menu bar (the application's main menu or pull-down menu); contextual (pop-up) menu; window (system) menu for changing the size and position of the application window.

A toolbar is a line on which the most frequently used commands, buttons or icons, and drop-down lists are located. The toolbar provides quick access to commands.

35.Types of operating systems. WINDOWS operating system - main features.

Types of operating systems by data processing method:

· Batch OS(batch) - to perform specific tasks there are corresponding programs that are executed sequentially. The user does not have the opportunity to interfere with the execution process; in other words, there is no interactivity in such OSs. New jobs are added to the queue and executed sequentially.

· Time-sharing OS(time-sharing) - The OS divides processor time into periods that are allocated to application programs according to predefined rules. Time-sharing operating systems allow you to run multiple applications simultaneously (mutlitasking) and allow multiple users to work simultaneously on the same computer. Time-sharing OS is interactive. Modern operating systems are built using time sharing technology.

· Real time OS(real-time) - designed for mission-critical applications in which the accuracy of response time is important. Such applications include medical tracking systems, anti-lock braking systems in cars, control systems for nuclear power plants, etc.

Graphic (with a graphical user interface - GUI) - text (command line only);
free - paid;

Open (with the ability to edit the source code) - closed (without the ability to edit the source code);

Client - server;

High stability (resistance to hardware failures) - low stability;

Easy to administer (for the average user) - complex for system administrators;

16-bit - 32-bit - 64-bit (in the distant past there were also 8-bit);

With a high level of data security - with a low level of security;

Operating system concept

There are two groups of OS definitions: “a set of programs that control hardware” and “a set of programs that control other programs.” Both of them have their own precise technical meaning, which, however, becomes clear only with a more detailed consideration of the question of why operating systems are needed at all.

Windows performs the following main functions:

· Convenient, visual graphical user interface.

· Multitasking, i.e. execution of several programs simultaneously.

· Unification of the use of computer hardware resources.

Windows Features:

· Rules for writing a program. To work in the Windows environment, the program must be written according to certain rules that differ significantly from those adopted in MS-DOS.

Windows allows you to run programs written for MS DOS, but the programs cannot take advantage of Windows.

· GUI user interface in Windows is based on the idea of ​​a window interface, which is also adopted in a number of other modern operating systems (for example, UNIX). Each program has its own window in which messages are exchanged with the user. For clarity, Windows widely uses icons (pictograms) depicting individual programs.

In addition, the Windows interface is largely standardized, making it easier for users to learn new programs.

· Multitasking. Multitasking mode allows you to run several applications at the same time, for example, a word processor, database, game and switch between them.

· Exchange data between applications. In addition, data exchange between applications is possible, which allows, for example, information created in a spreadsheet to be transferred to a text document via the clipboard.



 

It might be useful to read: