Controls. Common properties Height – Height of the control Left – Left of the control Width – width of a control Top - From the screen top Font – Foreground.

Slides:



Advertisements
Similar presentations
Working with Intrinsic Controls and ActiveX Controls
Advertisements

Chapter 3 Creating a Business Letter with a Letterhead and Table
Chapter 1: An Introduction to Visual Basic 2012
What is a Dialog box? A Dialog box is a window or “form” that contains other child windows or “controls” that have a specific appearances and pre-defined.
© by Pearson Education, Inc. All Rights Reserved. continued …
XP New Perspectives on Microsoft Office Excel 2003, Second Edition- Tutorial 3 1 Microsoft Office Excel 2003 Tutorial 3 – Developing a Professional- Looking.
1 Lab6 Lab6 ComboBox Control Properties, Methods and Events.
IS 1181 IS 118 Introduction to Development Tools VB Chapter 03.
Flowchart Start Input weight and height
VB Default Controls List Box, Combo Box
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.
CVEV 118/698 Visual Basic Lecture 3 Prof. Mounir Mabsout Elsa Sulukdjian Walid El Asmar.
Copyright 2003 : Ismail M.Romi, PPU. All Rights Reserved 1 Lab2 Managing Controls.
1 Introduction to the Visual Studio.NET IDE Powerpoint slides modified from Deitel & Deitel.
Fundamentals of Programming in Visual Basic 3.1 Visual basic Objects Visual Basic programs display a Windows style screen (called a form) with boxes into.
XP 1 Microsoft Office Excel Developing a Professional-Looking Worksheet.
Controls General Discussion. VB Controls Visual Basic Controls A control is the generic name for any object placed on a form Controls may be images,
 Insert a picture from a file  Move and delete images  Use the Picture Tools tab  Add styles, effects, and captions to images  Resize photos  Use.
BIM313 – Advanced Programming Simple Controls 1. Contents Traditional Controls – Labels, Text Boxes, Buttons, Check Boxes, List Boxes, Combo Boxes Advanced.
XHTML Introductory1 Forms Chapter 7. XHTML Introductory2 Objectives In this chapter, you will: Study elements Learn about input fields Use the element.
Lab 9 – User Forms Design. User Forms What are user forms? –Known as dialog boxes –Major ways for getting user input An example of using user forms: Monthly.
XP New Perspectives on Microsoft Office FrontPage 2003 Tutorial 4 1 Microsoft Office FrontPage 2003 Tutorial 4 – Using Shared Borders and Themes.
IE 411/511: Visual Programming for Industrial Applications
Chapter 12: Using Controls. Examining the IDE’s Automatically Generated Code A new Windows Forms project has been started and given the name FormWithALabelAndAButton.
Chapter 2 More Controls Programming in C#. NET © 2003 by The McGraw-Hill Companies, Inc. All rights reserved.
Microsoft Office Excel 2003 Tutorial 3 – Developing a Professional-Looking Worksheet.
Adobe Dreamweaver CS3 Revealed CHAPTER FIVE: USING HTML TABLES TO LAY OUT A PAGE.
Tutorial 7 Creating Forms. Objectives Session 7.1 – Create an HTML form – Insert fields for text – Add labels for form elements – Create radio buttons.
CIS 338: VB.NET Components Dr. Ralph D. Westfall April, 2011.
Chapter 9 - VB.Net by Schneider1 Chapter 9 – Additional Controls and Objects 9.1 List Boxes, Combo Boxes, and the File-Opening Control The List Box Control.
ListBox, ComboBox, Menu Chapter 5.4, ComboBox Control: Properties & Methods u Combines TextBox features with a short drop- down list  cboOne.AddItem(string)
1. Chapter 4 Customizing Paragraphs 3 More Paragraph Changes Highlight a paragraph in Word by applying borders and shading. Sort paragraphs to control.
Format the Presentation. Selecting and Deselecting Objects 1.An object cannot be manipulated until it is selected. 2.Select various objects on PowerPoint.
Chapter One An Introduction to Visual Basic 2010 Programming with Microsoft Visual Basic th Edition.
Graphical User Interfaces 2 Tonga Institute of Higher Education.
T U T O R I A L  2009 Pearson Education, Inc. All rights reserved. 1 3 Welcome Application Introduction to Visual Programming.
CHAPTER TWO Creating Simple Visual Basic.NET Windows Applications.
Laboratory Exercise # 9 – Inserting Graphics to Documents Office Productivity Tools 1 Laboratory Exercise # 9 Inserting Graphics to Documents Objectives:
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. WORD 2007 M I C R O S O F T ® THE PROFESSIONAL APPROACH S E R I E S Lesson 15 Advanced Tables.
Chapter 2 – Introduction to the Visual Studio .NET IDE
Visual C# 2012 How to Program © by Pearson Education, Inc. All Rights Reserved.
CHAPTER:07 JAVA IDE PROGRAMMING-II Prepared By Prepared By : VINAY ALEXANDER ( विनय अलेक्सजेंड़र ) PGT(CS),KV JHAGRAKHAND.
Visual Basic Programming Introduction VB is one of the High level language VB has evolved from the BASIC language. BASIC stands for Beginners All-purpose.
More User Interface Controls User interface controls are located in the toolbox. Click the +/- signs to open/ close the different tabs of the tollbox.
McGraw-Hill/Irwin Programming in Visual Basic 6.0 © 2002 The McGraw-Hill Companies, Inc. All rights reserved. Update Edition Chapter 2 More Controls.
1 Visual Basic Part I - A tool for customizing your program Principles of GIS
Copyright (c) 2003 by Prentice Hall Provided By: Qasim Al- ajmi Chapter 3 Some Visual Basic Controls and Events Visual Basic. NET.
Slide 1 VB Graphics Controls & Timer Control. Slide 2 Default Controls.
CMPF114 Computer Literacy Chapter 3 The Visual Basic Environment 1.
Chapter 20. Copyright 2003, Paradigm Publishing Inc. CHAPTER 20 BACKNEXTEND 20-2 LINKS TO OBJECTIVES Create, Format, and Customize Drawn Objects Create,
Chapter 2 More Controls Programming in C#. NET Objectives Use text boxes, group boxes, check boxes, radio buttons, and picture boxes effectively.
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
IMS 3253: Controls 1 Dr. Lawrence West, MIS Dept., University of Central Florida Topics Check Boxes Radio Buttons Date Time Picker Masked.
TOOLBOX. The Toolbox Intrinsic Controls - always included in the Toolbox ActiveX Controls - separate files with ocx file extension Insertable Objects.
PowerBuilder Window Window Controls Window Properties Window Types
COMPUTER PROGRAMMING I 3.01 Apply Controls Associated With Visual Studio Form.
 2002 Prentice Hall. All rights reserved. 1 Introduction to the Visual Studio.NET IDE Outline Introduction Visual Studio.NET Integrated Development Environment.
1 Chapter 6: Creating Oracle Data Block Forms. 2 Forms  Application with a graphical user interface that looks like a paper form  Used to insert, update,
 You won’t write a single line of program code.  Instead, you’ll use visual programming techniques.  Visual Studio processes your actions (such as mouse.
Chapter 1: An Introduction to Visual Basic 2015
Introduction to Computing
Chapter 2 – Introduction to the Visual Studio .NET IDE
3.01 Apply Controls Associated With Visual Studio Form
3.01 Apply Controls Associated With Visual Studio Form
VB 6.0.
Visual Basic.
DREAMWEAVER MX 2004 Chapter 3 Working with Tables
P.J.Balakumaran, AP, Commerce CA, SNMV CAS
3.Visual Basic Controls.
Chapter 4 Enhancing the Graphical User Interface
Presentation transcript:

Controls

Common properties Height – Height of the control Left – Left of the control Width – width of a control Top - From the screen top Font – Foreground color Name – It is used to identify the control in the code Backcolor – background color Enabled – whether user can access or not Visible – Whether it is visible to the user Appearance – Graphical or standard

Label It is a graphical control that is used to display text. This text cannot be edited directly. Properties: Caption : This is used to change the text displayed in the control. Autosize :This causes the control to horizontally expand and adjust to the size of the contents. Two values are allowed : true or false Wordwrap : This is used to resize the text entered in the caption property.If the text exceeds, the text wraps in the next line.

Command Button It is also known as push button. It is used to begin,interrupt or end a particular process. Access keys can e attached to that by placing an ampersand before the character. Properties: Caption : This property determines the text displayed on the command button. Backcolor : Only available with Graphical style. Style : It is used to create graphical buttons. Value o means standard, 1 means Graphical Picture : We can load images into a button Event : Click

Textbox A text box is used to accept information from user at runtime, can also be used to display text that user can edit at runtime. It can be used with the data control to display information from a database. Properties : Multiline : It is used to write multiple lines. It can be true or false Alignment : It can be used to set the alignment of text within the textbox. Values : Left, Right, Center

Checkbox It is used to give the user true or false option. It is used to select one more option from the choices. Properties : Caption – It specifies the text appears beside the checkbox Value : This is used to specify the state of a checkbox. 0 means deselected and 1 means selected Events : Click event

Option Button It is a round radio button that you select to turn an option on or off. Properties : Value : This property returns or sets the state of the option button Caption : It specifies the text that appears beside the option button Events : Click

Frame Control It is a container for other controls typically option buttons or check boxes. Caption : it specifies the text to be displayed as the caption Enabled : It is used to determine whether control can respond to user generated events.

List Box This control displays a list from which user can select one or more items. User can’t edit the data in the listbox directly. VB adds the scroll bar when the list is too big. Properties: Listcount : It returns the number of items in the list List index : Index of the selected item in the list. Index starts with zero List : This is an array holds the list’s item.List(0) holds the first item Multiselect : Simple

Methods : Additem : to add the items in the runtime. removeitem: to remove a particular item clear : It clears the entire listbox Events : Click

Combo Box It comes from combination of list and textbox. User can either enter data in the textbox or select an item from the list box. It can also be used to create a drop down list box.

Picture and Image Control The Image control displays graphics on your Form window. The graphics reside in a file, and the Image control determines how that file's graphic image will appear onscreen. The Picture Box control works almost exactly like the Image control, with these exceptions: The Picture Box control supports more properties, events, and methods than the Image control. The Picture Box control consumes more resources than the Image control and, therefore, is not as efficient.

Data types supported by Image.bmp A Windows bitmap image file.cur An animated cursor.dib An older bitmap image format.emf An enhanced Windows metafile extension.gif A Graphic Interchange Format file often used on Web pages.ico An icon file.jpg The JPEG image format that stores graphics in a highly compressed format.wmf A Windows metafile

Differences between two Image Control It takes less resources. Refresh rate is higher The Image control shrinks and grows It cannot be added in MDI Picture Control It takes more resources. Refresh rate is lower The Picture Box control automatically clips the image if it will not fit within the Picture Box control's borders that you set when you placed the Picture Box control. It can be added in MDI

Image control Properties : Picture : To load the picture in the control Stretch : whether graphic image has to be resized or not Picture control : Picture : To load the picture in the control Autosize : Whether the control has to be resized or not Method : Loadpicture Event: click

Scrollbar Scrollbars let users control value changes. The toolbox includes both a Horizontal Scrollbar and a Vertical Scrollbar control. Large Change Specifies the amount that the scrollbar changes when the user clicks within the scrollbar's shaft area. Max Indicates the maximum number of units that the scrollbar value represents at its highest setting. The range is from 1 to 32,767 (the default Max value).

Min Indicates the minimum number of units the scrollbar value represents at its lowest setting. The range is from 1 (the default Min value) to 32,767. SmallChange Specifies the amount that the scrollbar changes when the user clicks an arrow at either end of the scrollbar. Value Contains the unit of measurement currently represented by the position of the scrollbar. Events : Change() : when the value changes Scroll() : When we drag the thumb

Timer control The Timer control always works in the background, and the user never sees the timer on the form in the runtime. The timer's purpose is to work in the background, triggering an event every once in a while according to the clock ticks. Properties : Interval : in millisecond Enabled : Whether timer event to be occurred or not Events : Timer()

File controls Drivelistbox : It lists the existing drives from the system Property : Drive At runtime, you can set the drive list box's Drive property. The Drive property will contain the name of the drive as well as the volume label on the drive. Dirlistbox : It shows the directories according to the drive. Property Path At runtime, you can set the directory list box's Path property. The Path property contains the name of the disk drive as well as the full path. Events : Change()

Filelistbox: It lists out the files existing in the particular directory. Properties : Pattern :Contains a wildcard pattern of files. * in the pattern indicates all files, and ? means all characters. Filename : It shows the name of the file. Path : It returns the path of a particular file.

Shape It is used to draw different shapes. Property : Shape : It determines the shape 0 – Rectangle 1 – Square 2 – Oval 3 – Circle 4 – Rounded Rectangle 5 – Rounded Square

Line Used to draw the line Properties : Border Width – Thickness of the line BorderStyle – Type of Line 1 – Solid 2- Dash 3 – Dot etc..

Listbox and combobox: It provides a set of choices that are displayed vertically in a single column.Scrollbars appears automatically if the list exceeds the size. Combobox combines the feature of textbox and a Listbox.This control enables the user to type a text or selecting from the list. Scrollbar : It enables the user to select a value by positioning it at the desired location.

Common Properties Apperance Back Color Height Width Font Picture Tabindex Tabstop

Textbox Max characters:2048 chracters or 32kb (multiline property true) Text maxlength Sellength Seltext Passwordchar Multiline(read only only at design time)

Advanced controls Common Dialog Control:It provides services to the application like open,save,save as,Font Statusbar: It is a control that displayed at the bottom of the application and displays the current state of the application. Imagelist: It is basically list of images.it stores a collection of pictures.It doesnot contain anything visible at runtime. Treeview :It is used to display information within a tree hierarchy.A treeview is made up of nodes that are related to each other. Progrssbar: It gives the user some visual feedback on what’s happening during a time consuming operation.

To display various dialog Boxes: ShowOpen: Action property :1 Showsave : Action property :2 ShowColor : Action property :3 showFont : Action property :4 Showprinter : Action property :5 ShowHelp: Action property :6

Read Only properties Textbox : name, multiline,hideselection,hwnd,index,scrollbars Listbox : Name, index, hwnd, sorted, style, mulitselect Listcount, selcount, newindex Combobox : name,hwnd, index, listcount, selcount, newindex,sorted