14
1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

  • View
    218

  • Download
    1

Embed Size (px)

Citation preview

Page 1: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

1

Prototyping for HCI

Spring 2004 (Week 10)Jorge A. Toro

Page 2: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

2

The Language

Custom Controls

Page 3: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 3

Custom Controls

Controls are graphic objects that represent the properties or operations of other objects

VB.NET Allows you to create your own set of controls

Page 4: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 4

Page 5: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 5

Page 6: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 6

Page 7: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 7

Custom Controls

There are different kinds of custom controls We will focus in the simplest ones You can add any controls you want similar to

what you do when creating forms

Page 8: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 8

Example

Custom label

Page 9: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 9

Custom Controls

Page 10: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 10

Adding properties

Two sections Get

What the property returns if someone tries to read it

Set What the property

receives if someone tries to write in it

Public Property Title() Get Return label1.text End Get Set(ByVal Value) label1.text = Value End SetEnd Property

Page 11: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 11

Using the Control

The custom control will appear in the control toolbox.

Drag the control over the form just as any other control.

Warning! You need to compile the project first before putting the control in.

Page 12: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 12

Page 13: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 13

Using the control

The properties window will show the properties you defined for the control as well as others that come by default

Page 14: 1 Prototyping for HCI Spring 2004 (Week 10) Jorge A. Toro

HCI430 – J.Toro 14

Questions?