Access-shape.

click fraud protection

Access is a powerful application Windows, database management system (DBMS).His mission - to provide information to the user in a convenient form, automation operations, which are often repeated.The program also helps in finding and storing data.All these operate Access-shape.Creating forms - simple task, designed to help the user as much as possible.

in the form of Access, both the shop window, it is convenient to open and view the desired items.Since the shape - is the entity to which users can add, edit and display data stored in Access, its appearance is important.

If the database classical Access applications used by multiple users, a well-designed form - the key to accuracy and efficiency of work with them.

Creating forms

Access database provides the user with a convenient mechanism for working with data.This Access-specific forms that are much easier to input data editing, viewing them.They are a special object in the database and have a large arsenal of controls with which occurs automation of data stored in database tables.This text fields, check boxes, radio buttons, drop-down lists, and more.

ways to create diverse forms in Access:

  • create forms based on existing tables and queries;
  • creating blank forms;
  • divided form;
  • forms with multiple accounts;
  • subordinates Access-form.

Create a form by using the Form Wizard, special designer.

They are particularly useful if, for example, input data must be done with special forms.For this kind of form, the data entry fields do specifically the same as those on the blank.

form based on an existing table

Creating forms in Access, based on an existing table is very simple.To do this, see "Creating a" need to click the button "Form".The main condition in this case is that you have to create a table with data, as well as her choice in the navigation area.The form is displayed only one entry, and data related table.

To display multiple records in table form should be in the same section, "Creating a" select button "several elements".So we will be able to display in text form fields a number of data records from all fields of the table.

On the basis of an existing table creation forms in Access, you can also develop as a divided form.This view, which, together with the presentation of data in the controls is parallel to the sample data in tabular form.To create a split form, it is necessary in the "Create" button to select "Split Form".

Such forms appear even once formatted with multiple controls.Most often these are the elements of the single-line text fields, which are displayed in the fields of the table stored data values.Instead of pre-formatted, you can do an empty form.

layout mode

Ready-to-use table is put on the form.In this mode, you can change only the actual data records of database tables, to move between the records.Formatting in this mode is not allowed, and the creation of a Microsoft Access form requires formatting controls, and the form itself.All this can be done if the switch to the layout or design mode.

layout mode is different from the design mode fewer opportunities for the design of forms.However, it is very convenient for quick formatting, to make minor changes to the controls: a vertical or horizontal alignment of them, adding more text fields, changing the style of the shape and so on.In the layout mode you can not change the data output in the controls, while the design mode provides such an opportunity.

Setting form in design mode is more complicated and profound.In addition, only in design mode is available a number of elements of graphic design, as well as controls: rectangles, lines, buttons, combo boxes, radio buttons, and more.In this mode, you can change the data source for an editable form.Moreover, this mode you can turn off the layout.

Adding to the shape buttons

For example, you need to add a button to the form with which it will have to close.The design mode is available to the whole layout of the various controls, such as a button.If you add it to the layout of the form, the database will automatically Wizard button, a window is displayed to the user.

creation window buttons offer a choice of several categories, which contain lists of actions.In this case, you must choose the category "Working with the form."From the list of actions in this category to choose "Close the form."

The following is necessary to inform the user that the button is responsible for the closing of the form.You can leave the text on the button, and you can tell about this with the icon (picture).

Next the wizard prompts the user to name the button, and then you can click "Finish" - so get ready for a button on a form that will allow it to close.

If you now click on the button created, the database will offer to save the changes created in the form, and then close it.In Design view, this can not work a button.It operates only in the formulation.

It should also be said that the forms themselves can be formed with the help of a special master.During the construction of the master mold need only determine its settings.Next, create a master shape easily format at its discretion, by switching to the layout or design mode.

Subforms

subform - an element that is a complement of the other, the main Access-form.Creating forms submission - is the development of the hierarchical structure of the two tables, reflecting the existence of relations between forms.

relations between them may represent a different type of communication is available between database tables, "one-to-many" "many-to-many".Often, these relationships are considered in the context of family relationship with the presence of the parent (main) form and the child (subordinate).

What subform

Creating subforms in Access can be explained by an example: this form can be a form of customer orders in the online store.

Customer information contained in one table, and information about its orders are stored in the other in connection with the normalization of the design of the database.One buyer meets several demands, so the relationship between the customer and orders tables reflect the relationship "one-to-many".In this case, the form, the data representing the buyer, will become the mainstream.Another representing the data of his orders, will be added to the core and will be subordinate.

placed in the same space and the basic layout of the subform show only related data.For example, if the table is a unique buyer customers, and in this table orders it involves three entries, then subform displays all three records of his orders.

Form Wizard

create a hierarchical structure of forms in Access, you can in different ways.For example, realizing creation script and the main and subordinate forms, you can resort to the help of the master form.

Create a main form in Access, containing subordinate, using the wizard will not be easy.It will not only create the forms themselves, but also connect them with the necessary attitude.If the scenario involves the creation of a form submit it to add to the existing main, then you can either use a wizard, or simply drag and drop an existing table on the main layout and make it subordinate.

Creating forms of subordination

Create subforms from two related tables (Authors and Books).For this we use the master form.First of all, open the master himself, the team performance is located in the database Access (form creation).In Access 2007, for example, it can be found in the drop-down list item "Other forms".

The window wizard prompts you to select the table for which it is necessary to create forms and fields (selection by double-clicking), which the user would like to see.After the first table in the same window, you will need to choose another that has a connection with the first.Master will detect relationships, and if he can not do it, then create subforms he simply can not.In this case, the slave becomes a form created on the basis of the table Books.

the next step, the wizard prompts you to choose the type of data.We need to choose the "Subforms" and then again press the button "Next".

next step will enable us to choose the appearance of created forms: tape or table layout.I must say that the tape richer in style.

In the last step we need to customize the form's title, then press "Done" - will remain subordinated to access the form.Creating forms completed.

create designs can be switched to the designer or layout.It will need to format the resulting field, or add other controls.

Creating a Switchboard in Access

presence of a large number of tables in the database, as well as the forms associated with the data in these tables, greatly complicates the overall database schema.To facilitate movement between the base forms, creating the so-called Main Switchboard form.This is a common element that can be edited in the designer at its discretion.It can be said that by creating a Main Switchboard form, you have carried out the creation of database forms in Access, which is its primary or splash page.

Use the buttons placed on it a lot easier to move between elements, as each button is associated with a separate form.Click on the button causes the database to perform the transition to the table associated with the button.

Operation Manager

In Access creation of the Main Switchboard form by a special controller.Switchboard Manager is under working with databases.If it is the first time, it will not push shapes and create an offer.Wizard window will appear containing several buttons from which you can select "Change."So you can go to the setup communications function Switchboard and other available forms of database.

example, add two buttons - "Button 1" and "Button 2" - on the Main Switchboard form.These buttons Contact form Authors1 and Books, which is subordinate.By selecting "New", we will open a dialog where you specify the desired name for the button and the action that we need to perform ("Open the form to change").In the third field, enter the form with which we want to link adds a button.

closing the settings window, we find that in the navigation window appeared our Switchboard form.By selecting it in the navigation pane, open the window and see that it contains a simple design style and two buttons.Click on the buttons will cause the database to open the form to which the button is linked.

Section tables

In the table after the operation can be found to add a new table called Switchboard Items.It stores all the settings associated with creating Switchboard.In our case, there is only one button form with two buttons, so she put all three entries:

  • recording the buttons contained on the form,
  • the actions associated with them,
  • record of the Switchboard.

Design Mode

The created Switchboard form can be complicated by reformatting its contents in Design.With it, on its surface, you can add many other useful controls.

Main Switchboard form also has the ability to link with other similar shapes.This is a useful feature for scheduling transitions between forms in a very large database where there is room for a variety of sections and categories.