Graphical User Interface Concepts - Part 2 Session 09 Mata kuliah: M0874 – Programming II Tahun: 2010.

Slides:



Advertisements
Similar presentations
Information System Design Lab 5&6. User Interface Design.
Advertisements

Introduction to Visual Basic.NET Uploaded By: M.Sheraz anjum.
 2006 Pearson Education, Inc. All rights reserved Graphical User Interface Concepts: Part 2.
© by Pearson Education, Inc. All Rights Reserved.
Visual Basic 2010 How to Program. © by Pearson Education, Inc. All Rights Reserved.2.
Visual Basic 2010 How to Program Reference: Instructor: Maysoon Bin Duwais slides Visual Basic 2010 how to program by Deitel © by Pearson Education,
C# Programming: From Problem Analysis to Program Design1 9 Programming Based on Events.
C# Programming: From Problem Analysis to Program Design1 Programming Based on Events C# Programming: From Problem Analysis to Program Design 3 rd Edition.
Programming Based on Events
Graphical User Interface (GUI) A GUI allows user to interact with a program visually. GUIs are built from GUI components. A GUI component is an object.
MDI windows Single-document-interface (SDI)
ListBoxes The list box control allows the user to view and select from multiple items in a list. CheckedListBox control extends a list box by including.
Group Boxes and Panels Arrange components on a GUI Buttons and etc. can be placed inside a group box or panel. All these buttons move together when the.
CVEV 118/698 Visual Basic Lecture 3 Prof. Mounir Mabsout Elsa Sulukdjian Walid El Asmar.
Programming Based on Events
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
Chapter 13: Advanced GUI and Graphics
Creating Menu. Objectives Create a menu system for a form –Create a menu –Create a menu titles –Create a menu items –Create a submenu –Modify menu –Edit.
CA 121 Intro to Programming Tariq Aziz and Kevin Jones GUI Programming in Visual Studio.NET Chapter 3 Tariq Aziz and Kevin Jones.
BİL528 – Bilgisayar Programlama II Advanced Controls, Menus, Toolbars, and Status Bars 1.
Microsoft Visual Basic 2005 ENRICHMENT CHAPTER Visual Studio Tools for Office.
BIM313 – Advanced Programming Simple Controls 1. Contents Traditional Controls – Labels, Text Boxes, Buttons, Check Boxes, List Boxes, Combo Boxes Advanced.
1 Graphical User Interfaces Part 2 Outline Multiple Document Interface (MDI) Windows Visual Inheritance User-Defined Controls.
 2009 Pearson Education, Inc. All rights reserved Graphical User Interfaces with Windows Forms: Part 2.
IE 411/511: Visual Programming for Industrial Applications
Menus,MonthCalender, DateTimePicker, MDI,Tree View, List View,
Chapter 12: Using Controls. Examining the IDE’s Automatically Generated Code A new Windows Forms project has been started and given the name FormWithALabelAndAButton.
Adding User Interactivity – Lesson 51 Adding User Interactivity Lesson 5.
T U T O R I A L  2009 Pearson Education, Inc. All rights reserved Typing Application Introducing Keyboard Events, Menus, Dialogs and the Dictionary.
T U T O R I A L  2009 Pearson Education, Inc. All rights reserved. 1 2 Welcome Application Introducing the Visual Basic 2008 Express Edition IDE.
Some Interesting Controls. Controls We've UsedNew Controls LabelListBox TextBoxCheckedListBox ComboBoxTabControl ButtonTabPage Menu MenuItem TreeView.
Productivity Programs Common Features and Commands.
Computing Fundamentals Module Lesson 3 — Changing Settings and Customizing the Desktop Computer Literacy BASICS.
ListBox, ComboBox, Menu Chapter 5.4, ComboBox Control: Properties & Methods u Combines TextBox features with a short drop- down list  cboOne.AddItem(string)
 2009 Pearson Education, Inc. All rights reserved Graphical User Interfaces with Windows Forms.
© Copyright by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Chapter 13 – Graphical User Interfaces Part 2 Outline.
Chapter One An Introduction to Visual Basic 2010 Programming with Microsoft Visual Basic th Edition.
Program Design and Coding
Microsoft Visual Basic 2010 CHAPTER THREE Program Design and Coding.
Graphical User Interfaces 2 Tonga Institute of Higher Education.
Computer Information Technology – Section 4-1 Some text and examples used with permission from:
Creating Graphical User Interfaces (GUI’s) with MATLAB By Jeffrey A. Webb OSU Gateway Coalition Member.
Visual C# 2012 How to Program © by Pearson Education, Inc. All Rights Reserved.
Visual C# 2012 How to Program © by Pearson Education, Inc. All Rights Reserved.
© Copyright by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 1 Outline 2.1 Test-Driving the Welcome Application 2.2.
Win32 Controls & ActiveX Integration In this presentation… –Introduction to the new Win32 controls. What they are? How they are enabled? Potential uses.
Object-Oriented Application Development Using VB.NET 1 Chapter 10 VB.NET GUI Components Overview.
Lesson: 2 Common Features and Commands After completing this lesson, you will be able to: Identify the main components of the user interface. Identify.
Menus Menus provide groups of related commands for windows applications Menu, menu items, submenus A menu item that contains a submenu is considered to.
Slide 1 Using Menu Bar & Common Dialog Boxes. Slide 2 Setting Up the Main Items v First open the form on which you want the menu located v Then start.
Creating Menus Menu Bar – behaves like standard Windows menus Can be used in place of or in addition to buttons to execute a procedure Menu items are controls.
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
IE 411/511: Visual Programming for Industrial Applications Lecture Notes #2 Introduction to the Visual Basic Express 2010 Integrated Development Environment.
PowerBuilder Window Window Controls Window Properties Window Types
Visual Basic.NET BASICS Lesson 14 Menus and Printing.
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
Graphical User Interfaces Part 2 1 Outline TreeViews ListViews Tab Control.
 2002 Prentice Hall. All rights reserved. 1 Introduction to the Visual Studio.NET IDE Outline Introduction Visual Studio.NET Integrated Development Environment.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 6 Looping and Multiple Forms.
Chapter 7 Multiple Forms, Modules, and Menus. Section 7.2 MODULES A module contains code—declarations and procedures—that are used by other files in a.
Graphical User Interface Concepts - Part 1 Session 08 Mata kuliah: M0874 – Programming II Tahun: 2010.
Dive Into® Visual Basic 2010 Express
Graphical User Interface
3.01 Apply Controls Associated With Visual Studio Form
1. Introduction to Visual Basic
3.01 Apply Controls Associated With Visual Studio Form
Windows Forms GUI: A Deeper Look
Creating a Windows Forms User Interface
Visual C# - GUI and controls - 1
Overview of the IDE Visual Studio .NET is Microsoft’s Integrated Development Environment (IDE) for creating, running and debugging programs (also.
Presentation transcript:

Graphical User Interface Concepts - Part 2 Session 09 Mata kuliah: M0874 – Programming II Tahun: 2010

Bina Nusantara University 3 Outline Materi Menus LinkLabels ListBoxes and CheckedListBoxes ComboBoxes TreeViews ListViews Tab Control MDI Windows

Bina Nusantara University 4 Menus Menus provide groups of related commands for Windows applications. Menus are an integral part of GUIs, because they organize commands without “cluttering” the GUI.

Bina Nusantara University 5 Menus, submenus, and menu items

Bina Nusantara University 6 MenuStrip and ToolStripMenuItem properties and an event Description MenuStrip Properties MenuItemsContains the top-level menu items for this MenuStrip. HasChildrenIndicates whether MenuStrip has any child controls (menu items). RIghtToLeftCauses text to display from right to left. This is useful for languages that are read from right to left. ToolStripMenuItem Properties CheckedIndicates whether a menu item is checked. The default value is false, meaning that the menu item is unchecked. CheckOnClickIndicates that a menu item should appear checked or unchecked as it is clicked. IndexSpecifies an item’s position in its parent menu. A value of 0 places the MenuItem at the beginning of the Menu. MenuItemsLists the submenu items for a particular menu item.

Bina Nusantara University 7 MenuStrip and ToolStripMenuItem properties and an event Description ShortcutKeyDisplayStringSpecifies text that should appear beside a menu item for a shortcut key. If left blank, the key names are displayed. Otherwise, the text in this property is displayed for the shortcut key. ShortcutKeysSpecifies the shortcut key for the menu item. ShowShortCutKeysIndicates whether a shortcut key is shown beside menu item text. The default is true, which displays the shortcut key. TextSpecifies the menu item’s text. To create an Alt access shortcut, precede a character with &. Common ToolStripMenuITem Event ClickGenerated when an item is clicked or a shortcut key is used. This is the defaulte event when the menu is double-clicked in the designer.

Bina Nusantara University 8 LinkLabels The LinkLabel control displays links to other resources, such as files or web pages. A LinkLabel appears as underlined text (colored blue by default). When the mouse moves over the link, the pointer changes to a hand; this is similar to the behavior of a hyperlink in a web page. The link can change color to indicate whether it is not yet visited, previously visited or active.

Bina Nusantara University 9 LinkLabels A LinkLabel is the preferred control for indicating that the user can click a link to jump to a resource such as a web page, though other controls can perform similar tasks.

Bina Nusantara University 10 LinkLabel properties and an event Description Common Properties ActiveLinkColorSpecifies the color of the active link when clicked. LinkAreaSpecifies which portion of text in the LinkLabel is part of the link. LinkBehaviorSpecifies the link’s behavior, such as how the link appears when the mouse is placed over it. LinkColorSpecifies the original color of all links before they have been visited. The default color is set by the system, and is usually blue. LinkVisitedIf true, the link appears as though it has been visited. TextSpecifies the control’s text. UseMnemonicIf true, the & character in the Text property acts as a shortcut. VisitedLinkColorSpecifies the color of visited links. The default color is set by the system, and is usually purple. Common Event(Event arguments LinkLabelLinkClickedEventArgs) LinkClickedGenerated when the link is clicked. This is the default event when the control is double clicked in Design mode.

Bina Nusantara University 11 ListBoxes The ListBox control allows the user to view and select from multiple items in a list. ListBoxes are static GUI entities, which means that users cannot directly edit the list of items. The user can be provided with TextBoxes and Buttons with which to specify items to be added to the list, but the actual additions must be performed in code.

Bina Nusantara University 12

Bina Nusantara University 13 CheckedListBoxes The CheckedListBox control derives from ListBox and displays a CheckBox with each item. Items can be added via methods Add and AddRange or through the String Collection Editor. CheckedListBoxes allow multiple items to be checked, but item selection is more restrictive.

Bina Nusantara University 14

Bina Nusantara University 15 ComboBoxes The CombBox control combines TextBox features with a drop-down list-a GUI component that contains a list from which a value can be selected. A ComboBox usually appears as a TextBox with a down arrow to its right. By default, the user can enter text into the TextBox or click the down narrow to display a list of predefined items. If a user chooses an element from this list, that element is displayed in the TextBox.

Bina Nusantara University 16

Bina Nusantara University 17 TreeViews The TreeView control displays nodes hierarchically in a tree. Nodes are objects thTht contain values and can refer to other nodes. A parent node contains child nodes, and the child nodes can be parents to other nodes. Two child nodes that have the same parent node are considered sibling nodes. A tree is a collection of nodes, usually organized in a hierarchical manner. The first parent node of a tree is the root node.

Bina Nusantara University 18 TreeView properties and an event

Bina Nusantara University 19 TreeNode properties and methods

Bina Nusantara University 20 ListViews The ListView control is similar to a ListBox in that both display lists from which the user can select one or more items. ListView is more versatile and can display items in different formats. For example, a ListView can display icons next to the list items (controlled by its ImageList property) and show the details of items in columns.

Bina Nusantara University 21

Bina Nusantara University 22 Tab Control TabControl creates tabbed windows, such as those we have seen in Visual Studio. This allows you to specify more information in the same space on a Form and enables you to group displayed data logically. TabControls contain TabPage objects, which are similar to Panels and GroupBoxes in that TabPages also can contain controls. First ada controls to the TabPage objects, then add the TabPages to the TabControl. Only one TabPage is dispayed at a time. To add objects to the TabPage and the TabControl, write myTabPage.Controls.Add ( myControl ); myTabControl.TabPages.Add ( myTabPage );

Bina Nusantara University 23 TabControl properties and an event

Bina Nusantara University 24 MDI Windows Previously, we have built only single document interface (SDI) applications. SDI applications usually have limited abilties-Paint and Notepad for example have limited image-and text-editing features. To edit multiple documents, the user must execute another instance of the SDI application.

Bina Nusantara University 25 MDI Windows Many complex applications are multiple document interface (MDI) programs, which allow users to edit multiple documents at once. MDI programs also tend to be more complex-Paint Shop Pro and Photoshop have a greater number of image-editing features than does Paint. An MDI program’s main window is called the parent window, and each window inside the application is referred to as a child window. Although an MDI application can have many child windows, each has only one parent window.

Bina Nusantara University 26 MDI Windows In general, to add a child Form to a parent, write ChildFormClass childForm = New ChildFormClass(); childForm.MdiParent = parentForm; childForm.Show(); Child windows can be minimized, maximized and closed independently of the parent window.

Bina Nusantara University 27

Bina Nusantara University 28 References RzsC&pg=PA472&lpg=PA472&dq=control+properties+and+l ayout+c%23&source=bl&ots=LCz4YdGcOB&sig=kFd6TiqM Wz2y3u8rAfaMDfmRVAg&hl=id&ei=s6ROS7rwNsqLkAXlxf2 cDQ&sa=X&oi=book_result&ct=result&resnum=6&ved=0CC EQ6AEwBQ#v=onepage&q=&f=false &feature=relatedhttp:// &feature=related