S.2 Computer Literacy Question-Answer Book

Size: px
Start display at page:

Download "S.2 Computer Literacy Question-Answer Book"

Transcription

1 S.2 C.L. Half-yearly Examination ( ) S.2 C.L. Question- Answer Book Hong Kong Taoist Association Tang Hin Memorial Secondary School Half-yearly Examination S.2 Computer Literacy Question-Answer Book Date: 3 January 2012 Time: 8:30 a.m. 9:30 a.m. (1 hour) Instructions: 1. Full mark of this paper is This Question-Answer Book consists of 15 pages. 3. Attempt ALL questions. 4. Answer in complete sentences whenever applicable, or your effective communication marks will be deducted. Name Class Class Number Marks

2 S.2 C.L. Half-yearly Examination ( ) 2 Section A: Multiple Choice Questions (2M@, Total 30 marks) Put a in the box of the most suitable answer A B C D 1. Which of the following is a reserved keyword in Visual Basic? A. Visual B. Basic C. Project D. Class 2. Which of the following can be the name of a variable in Visual Basic? I. studentheight II. P&G III. 123Times A. I Only B. I, II Only C. II, III Only D. I, II and III 3. Which of the following is NOT a valid operator? A. + B. += C. Mod D Which of the following is NOT a property of a form? A. Left B. Number C. Text D. BackColor

3 S.2 C.L. Half-yearly Examination ( ) 3 5. Which of the following data types can be used to record the marks of a student in HKTA Tang Hin Memorial Secondary School? A. Integer B. Double C. Boolean D. Variable 6. Which of the following can be the value of a Boolean variable in Visual Basic? A. Yes B. No C. True D. Never 7. Which of the following statements contains an error? A. Label1.Text = Label2.Text + Label3.Text B. TextBox1.Left = 300 C. Me.Title = "234567" D. Button987.Enabled = False 8. The type of user interface with buttons, text boxes and labels is called A. GUI. B. CLI. C. prompt. D. SLI. 9. In Visual Basic, which operator is processed last? A. * B. ^ C. / D. \ 10. If you double click a button in the design view, the handler of which event is created? A. Click B. TextChanged C. DoubleClick D. Load

4 S.2 C.L. Half-yearly Examination ( ) Evaluate the VB expression Mod 12 \ 5 A. 1 B. 3 C. 4 D Which of the following statement will generate the dialog box below? A. MsgBox("Hello!" & vbcrlf & "I'm Stephanie.") B. MsgBox(Hello! & vbcrlf & I'm Stephanie.) C. MsgBox("Hello!" & vbcrlf & vbcrlf & "I'm Stephanie.") D. MsgBox(Hello! & vbcrlf & vbcrlf & I'm Stephanie.) 13. Study the following program, Public Class Form1 Private Sub Form1_Load(...) Handles MyBase.Load Dim x As Double = Val(InputBox("Enter x:")) Dim y As Double y = Math.Sqrt(x * x + 6) MsgBox(y) If the user enters 2.5 into the InputBox, what will be the output? A. 2.5 B. 3.5 C. 4.5 D. 5.5

5 S.2 C.L. Half-yearly Examination ( ) In the following program, the text box at the left is TextBox1, and the other is TextBox2. TextBox1 TextBox2 Public Class Form1 Private Sub Button1_Click(...) Handles Button1.Click Dim a As Integer Dim b As Integer a = TextBox1.Text b = TextBox2.Text b = a * 2 a = b + 3 Label1.Text = a + b When the user clicks Button1, the text in Label1 is changed to A. 6 B. 9 C. 12 D. 15

6 S.2 C.L. Half-yearly Examination ( ) Which of the code below will make the following change if we click Button1? TextBox1 TextBox2 A. Public Class Form1 Private Sub Button1_Click(...) Handles Me.Click TextBox2.AppendText(TextBox1.Text) B. Public Class Form1 Private Sub Button1_Click(...) Handles Me.Click TextBox2.Text = TextBox1.Text C. Public Class Form1 Private Sub Button1_Click(...) Handles Button1.Click TextBox2.AppendText(TextBox1.Text) D. Public Class Form1 Private Sub Button1_Click(...) Handles Button1.Click TextBox2.Text = TextBox1.Text

7 S.2 C.L. Half-yearly Examination ( ) 7 Section B: VB expressions (2M@, Total 10 marks) Convert the Mathematical expressions below to Visual Basic expressions. Mathematical Expression VB Expression e.g a = b + c a = b + c 1. v = u + at 2. A = 1 (a + b)h 2 3. m = y2 y1 x2 x1 (x1, x2, y1, y2 are names of variables.) 4. a = w 2 x 5. y = (a + b) 3 Section C: Coding (2M per line, Total 14 marks) Write the V.B. statement for the following operation for each case. Case Operation V.B. Statement(s) The text in Button1 changes to I m Button1.Text = "I'm clicked!" e.g. clicked! Title of the Form1 (as the current working form) becomes Hello!. The Button2 can be seen but cannot be clicked. The background colour of the Label3 becomes orange. 4. The TextBox4 cannot be seen. 5. The running programme stops running. 6. The Form5 appears while Form1 disappears. (Form1 is the startup and the current working form) (2 lines)

8 S.2 C.L. Half-yearly Examination ( ) 8 Section D: Programming (Total 15 marks) 1. Study the changes of this programme, fill in the blanks of the programme codes. [1M@, 5M] Step 1 When Form1 is loaded, the user is asked to enter his/her name, of which is represented by the variable inname. Step 2 As the user Jay enters his name, another interface like this appears. Line Programme code 1 Private Sub Form1_Load( ) Handles (1) 2 Dim inname As (2) 3 inname = (3) ("(4) ") 4 MsgBox("(5) ") 5

9 S.2 C.L. Half-yearly Examination ( ) 9 2. Study the changes of this programme, fill in the blanks of the programme codes. [1M@, 2M] Design View Step 1 Step 2 TextBox1 TextBox2 Button1 This is the design view of a form, with 4 labels, 2 textboxes and 1 button. All properties settings remain as the default values. Then, Form1 appears with the Button1 ( Check ) unable to be clicked. Button1 becomes clickable when the content in the TextBox2 is modified. Line Programme code 1 Private Sub TextBox2_TextChanged( ) Handles TextBox2.TextChanged 2 (1) = (2) 3

10 S.2 C.L. Half-yearly Examination ( ) Study the changes of this programme, fill in the blanks of the programme codes. 8M] Design view Step 1 Step 2 TextBox1 TextBox2 This is the design view of a form. The AutoSize property of Label3 is set as False. The user enters the class and class number into the two textboxes, e.g. 2E, 49. As Button1 is clicked, Label3 reveals the information as shown, and the values in TextBox1 and TextBox2 disappear. Step 3 Step 4 The user enters another set of values. Label3 reveals another set of responses.

11 S.2 C.L. Half-yearly Examination ( ) 11 Line Programme code 1 Private Sub Button1_Click( ) Handles Button1.Click 2 Dim inclass As (1) = TextBox1.Text 3 Dim innumber As Integer = (2) (TextBox2.Text) 4 Dim CheckDigit As (3) 5 Dim intext As String = (4) 6 CheckDigit = innumber (5) 7 Label3.Text = "(6) " & CheckDigit & "." & (7) & "If your Check Digit is 1, you are in odd number group." 8 TextBox1.Text = (8) 9 TextBox2.Text = intext 10

12 S.2 C.L. Half-yearly Examination ( ) 12 Section E: Debugging (Total 11 marks) Study this programme: Design view of the Form1 with Button1 as the Check out! button. Step 1 As the programme is loaded, user can enter the amount of fillet-o-fish and color s/he wants to buy. Step 2 As the user clicks the Check out! button, the amount to be paid is shown in another interface, with the Form1 changed like this. Background Colour : Red Step 3 As the user clicks the 確定 button, the Form1 disappears. Form1 disappear! Step 4 The last interface appears, and after clicking the 確 定 button on this interface, the programme stops.

13 S.2 C.L. Half-yearly Examination ( ) 13 Based on the flow shown above, the programme is as below, with 11 mistakes, and 1 mistake at each problem line. Line Programme code e.g. Private Sub Button1( ) Handles Button1 1 Dim numfillet Is Integer = Val(TextBox1.Text) 2 Let numcola be Integer = Val(TextBox2.Text) 3 Dim total As String 4 total = numfillet numcola Me.BackColor = ChangeTo.Red 6 Button1.Seen = False 7 MsgBox("Total: $" = total) 8 Me.Hidden() 9 MsgBox(Thank you for your purchase.) 10 Stop 11 Sub End Find out ALL of them and REWRITE the WHOLE programme line for each line. [1M@, 11M] Line Correct Version e.g. Private Sub Button1_Click( ) Handles Button1.Click

14 S.2 C.L. Half-yearly Examination ( ) 14 Section F: Comprehension (Total 20 marks) TextBox1 TextBox2 Button1 TextBox4 Figure 1 Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim sec, sec1, sec2 As String sec1 = TextBox1.Text sec2 = TextBox2.Text TextBox4.Text = sec1 + sec2 Figure 2 (a) Refer to the Figure 1 and Figure 2, what is the value in TextBox4 when the user enters 3600 into TextBox1 and 3800 into TextBox2 and then clicks Convert? (1 mark) (b) Refer to the Figure 1 and Figure 2, if the statement TextBox4.Text = sec1 + sec2 is changed to TextBox4.Text = Val(sec1) + Val(sec2), what is the value in TextBox4 if the user enters 3600 into TextBox1 and 3800 into TextBox2 and then clicks Convert? (1 mark) (c) Refer to the following program segment. h = i \ 3600 m = (i Mod 3600) \ 60 s = i Mod 3600 Mod 60 (i) What are the meanings of \ and Mod operators? (2 marks) (ii) Find the value of h, m and s if i = h is m is s is (6 marks)

15 S.2 C.L. Half-yearly Examination ( ) 15 (d) The program segment of part (c) is inserted into the program as shown below. Button1 TextBox1 TextBox2 TextBox3 TextBox4 Figure 3 Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim sec, sec1, sec2 As String Dim i, m, h, s As Integer sec1 = TextBox1.Text sec2 = TextBox2.Text sec = Val(sec1) + Val(sec2) i = Val(sec) h = i \ 3600 m = (i Mod 3600) \ 60 s = i Mod 3600 Mod 60 TextBox3.Text = h & "hours" & m & "minutes" & s & "seconds" TextBox4.Text = sec1 + sec2 Figure 4 (i) If the user enters into TextBox1 and 0.1 into TextBox2. I. What is the value of i. (1 mark) II. What are the values of TextBox3 and TextBox4 after the Convert button is clicked. (3 marks) (ii) If the user clicks the Convert button without any input, write down what you see in Form 1 on Figure 3. (3 marks) (iii) If the user now enters 0.1 into TextBox1 and into TextBox2 and then click Convert, will the values of TextBox3 and TextBox4 be the same as the result in part (d) (i)? If not, state their new values. (3 marks) * * * End of Paper * * *

Revision for Final Examination (Second Semester) Grade 9

Revision for Final Examination (Second Semester) Grade 9 Revision for Final Examination (Second Semester) Grade 9 Name: Date: Part 1: Answer the questions given below based on your knowledge about Visual Basic 2008: Question 1 What is the benefit of using Visual

More information

Introduction to. A revised course with - Concise concepts - Hands on class work. - Plenty of examples - Programming exercises

Introduction to. A revised course with - Concise concepts - Hands on class work. - Plenty of examples - Programming exercises Introduction to 1 A revised course with - Concise concepts - Hands on class work TextBox1 - Plenty of examples - Programming exercises Copyright HKTA Tang Hin Memorial Secondary School 2012 Contents Chapter

More information

Mr.Khaled Anwar ( )

Mr.Khaled Anwar ( ) The Rnd() function generates random numbers. Every time Rnd() is executed, it returns a different random fraction (greater than or equal to 0 and less than 1). If you end execution and run the program

More information

Else. End If End Sub End Class. PDF created with pdffactory trial version

Else. End If End Sub End Class. PDF created with pdffactory trial version Dim a, b, r, m As Single Randomize() a = Fix(Rnd() * 13) b = Fix(Rnd() * 13) Label1.Text = a Label3.Text = b TextBox1.Clear() TextBox1.Focus() Private Sub Button2_Click(ByVal sender As System.Object, ByVal

More information

Year 12 : Visual Basic Tutorial.

Year 12 : Visual Basic Tutorial. Year 12 : Visual Basic Tutorial. STUDY THIS Input and Output (Text Boxes) The three stages of a computer process Input Processing Output Data is usually input using TextBoxes. [1] Create a new Windows

More information

Objectives. After completing this topic, the students will: Understand of the concept of polymorphism Know on How to implement 2 types of polymorphism

Objectives. After completing this topic, the students will: Understand of the concept of polymorphism Know on How to implement 2 types of polymorphism Polymorphism Objectives After completing this topic, the students will: Understand of the concept of polymorphism Know on How to implement 2 types of polymorphism Definition Polymorphism provides the ability

More information

A Complete Tutorial for Beginners LIEW VOON KIONG

A Complete Tutorial for Beginners LIEW VOON KIONG I A Complete Tutorial for Beginners LIEW VOON KIONG Disclaimer II Visual Basic 2008 Made Easy- A complete tutorial for beginners is an independent publication and is not affiliated with, nor has it been

More information

In this tutorial we will create a simple calculator to Add/Subtract/Multiply and Divide two numbers and show a simple message box result.

In this tutorial we will create a simple calculator to Add/Subtract/Multiply and Divide two numbers and show a simple message box result. Simple Calculator In this tutorial we will create a simple calculator to Add/Subtract/Multiply and Divide two numbers and show a simple message box result. Let s get started First create a new Visual Basic

More information

VISUAL BASIC II CC111 INTRODUCTION TO COMPUTERS

VISUAL BASIC II CC111 INTRODUCTION TO COMPUTERS VISUAL BASIC II CC111 INTRODUCTION TO COMPUTERS Intended Learning Objectives Able to build a simple Visual Basic Application. 2 The Sub Statement Private Sub ControlName_eventName(ByVal sender As System.Object,

More information

IMS1906: Business Software Fundamentals Tutorial exercises Week 5: Variables and Constants

IMS1906: Business Software Fundamentals Tutorial exercises Week 5: Variables and Constants IMS1906: Business Software Fundamentals Tutorial exercises Week 5: Variables and Constants These notes are available on the IMS1906 Web site http://www.sims.monash.edu.au Tutorial Sheet 4/Week 5 Please

More information

DO NOT COPY AMIT PHOTOSTUDIO

DO NOT COPY AMIT PHOTOSTUDIO AMIT PHOTOSTUDIO These codes are provided ONLY for reference / Help developers. And also SUBMITTED IN PARTIAL FULFILLMENT OF THE REQUERMENT FOR THE AWARD OF BACHELOR OF COMPUTER APPLICATION (BCA) All rights

More information

Disclaimer. Trademarks. Liability

Disclaimer. Trademarks. Liability Disclaimer II Visual Basic 2010 Made Easy- A complete tutorial for beginners is an independent publication and is not affiliated with, nor has it been authorized, sponsored, or otherwise approved by Microsoft

More information

Tutorial 03 understanding controls : buttons, text boxes

Tutorial 03 understanding controls : buttons, text boxes Learning VB.Net Tutorial 03 understanding controls : buttons, text boxes Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple

More information

Learning VB.Net. Tutorial 17 Classes

Learning VB.Net. Tutorial 17 Classes Learning VB.Net Tutorial 17 Classes Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple applications, hope you enjoy it. If

More information

Visual Basic: Opdracht Structuur

Visual Basic: Opdracht Structuur Visual Basic: Opdracht Structuur HoofdMenu.vb SubMenu_Kwadraat.vb Form1.vb Form2.vb Submenu_Som.vb Form3.vb Form4.vb SubMenu_Gem.vb Form5.vb Form6.vb Form10.vb SubMenu_Naam.vb Form7.vb Form11.vb Form8.vb

More information

GUI Design and Event- Driven Programming

GUI Design and Event- Driven Programming 4349Book.fm Page 1 Friday, December 16, 2005 1:33 AM Part 1 GUI Design and Event- Driven Programming This Section: Chapter 1: Getting Started with Visual Basic 2005 Chapter 2: Visual Basic: The Language

More information

Learning VB.Net. Tutorial 10 Collections

Learning VB.Net. Tutorial 10 Collections Learning VB.Net Tutorial 10 Collections Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple applications, hope you enjoy it.

More information

"!#... )*! "!# )+, -./ 01 $

!#... )*! !# )+, -./ 01 $ Email engauday@hotmail.com! "!#... $ %&'... )*! "!# )+, -./ 01 $ ) 1+ 2#3./ 01 %.. 7# 89 ; )! 5/< 3! = ;, >! 5 6/.?

More information

1. Create your First VB.Net Program Hello World

1. Create your First VB.Net Program Hello World 1. Create your First VB.Net Program Hello World 1. Open Microsoft Visual Studio and start a new project by select File New Project. 2. Select Windows Forms Application and name it as HelloWorld. Copyright

More information

FOR 240 Homework Assignment 4 Using DBGridView and Other VB Controls to Manipulate Database Introduction to Computing in Natural Resources

FOR 240 Homework Assignment 4 Using DBGridView and Other VB Controls to Manipulate Database Introduction to Computing in Natural Resources FOR 240 Homework Assignment 4 Using DBGridView and Other VB Controls to Manipulate Database Introduction to Computing in Natural Resources This application demonstrates how a DataGridView control can be

More information

Chapter. Web Applications

Chapter. Web Applications Chapter Web Applications 144 Essential Visual Basic.NET fast Introduction Earlier versions of Visual Basic were excellent for creating applications which ran on a Windows PC, but increasingly there is

More information

Code: Week 13. Write a Program to perform Money Conversion. Public Class Form1

Code: Week 13. Write a Program to perform Money Conversion. Public Class Form1 Write a Program to perform Money Conversion. Week 13 Code: Public Class Form1 Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Dim a As Double a = TextBox1.Text If ComboBox1.SelectedItem

More information

Chapter 2 Exploration of a Visual Basic.Net Application

Chapter 2 Exploration of a Visual Basic.Net Application Chapter 2 Exploration of a Visual Basic.Net Application We will discuss in this chapter the structure of a typical Visual Basic.Net application and provide you with a simple project that describes the

More information

Unit 7. Lesson 7.1. Loop. For Next Statements. Introduction. Loop

Unit 7. Lesson 7.1. Loop. For Next Statements. Introduction. Loop Loop Unit 7 Loop Introduction So far we have seen that each instruction is executed once and once only. Some time we may require that a group of instructions be executed repeatedly, until some logical

More information

To enter the number in decimals Label 1 To show total. Text:...

To enter the number in decimals Label 1 To show total. Text:... Visual Basic tutorial - currency converter We will use visual studio to create a currency converter where we can convert a UK currency pound to other currencies. This is the interface for the application.

More information

Disclaimer. Trademarks. Liability

Disclaimer. Trademarks. Liability Disclaimer II Visual Basic 2010 Made Easy- A complete tutorial for beginners is an independent publication and is not affiliated with, nor has it been authorized, sponsored, or otherwise approved by Microsoft

More information

Check out the demo video of this application so you know what you will be making in this tutorial.

Check out the demo video of this application so you know what you will be making in this tutorial. Visual Basic - System Information Viewer Welcome to our special tutorial of visual basic. In this tutorial we will use Microsoft visual studio 2010 version. You can download it for free from their website.

More information

Unit 4. Lesson 4.1. Managing Data. Data types. Introduction. Data type. Visual Basic 2008 Data types

Unit 4. Lesson 4.1. Managing Data. Data types. Introduction. Data type. Visual Basic 2008 Data types Managing Data Unit 4 Managing Data Introduction Lesson 4.1 Data types We come across many types of information and data in our daily life. For example, we need to handle data such as name, address, money,

More information

Programming with Visual Studio Higher (v. 2013)

Programming with Visual Studio Higher (v. 2013) Programming with Visual Studio Higher (v. 2013) Contents/Requirements Checklist Multiple selection: using ifs & case While Loops Using arrays Filling arrays Displaying array contents Types of variables:

More information

COPYRIGHTED MATERIAL. Visual Basic: The Language. Part 1

COPYRIGHTED MATERIAL. Visual Basic: The Language. Part 1 Part 1 Visual Basic: The Language Chapter 1: Getting Started with Visual Basic 2010 Chapter 2: Handling Data Chapter 3: Visual Basic Programming Essentials COPYRIGHTED MATERIAL Chapter 1 Getting Started

More information

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Label1.Text = Label1.

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Label1.Text = Label1. 練習問題 1-1 Label1 Label1.Text = Label1.Text + 2 練習問題 1-2 Button2 Label1 Label1.Text = Label1.Text+ 2 Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click

More information

Developing Student Programming and Problem-Solving Skills With Visual Basic

Developing Student Programming and Problem-Solving Skills With Visual Basic t e c h n o l o g y Del Siegle, Ph.D. Developing Student Programming and Problem-Solving Skills With Visual Basic TThree decades have passed since computers were first introduced into American classrooms.

More information

MATFOR In Visual Basic

MATFOR In Visual Basic Quick Start t t MATFOR In Visual Basic ANCAD INCORPORATED TEL: +886(2) 8923-5411 FAX: +886(2) 2928-9364 support@ancad.com www.ancad.com 2 MATFOR QUICK START Information in this instruction manual is subject

More information

Learning VB.Net. Tutorial 19 Classes and Inheritance

Learning VB.Net. Tutorial 19 Classes and Inheritance Learning VB.Net Tutorial 19 Classes and Inheritance Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple applications, hope you

More information

COPYRIGHTED MATERIAL. Taking Web Services for a Test Drive. Chapter 1. What s a Web Service?

COPYRIGHTED MATERIAL. Taking Web Services for a Test Drive. Chapter 1. What s a Web Service? Chapter 1 Taking Web Services for a Test Drive What s a Web Service? Understanding Operations That Are Well Suited for Web Services Retrieving Weather Information Using a Web Service 101 Retrieving Stock

More information

フラクタル 1 ( ジュリア集合 ) 解説 : ジュリア集合 ( 自己平方フラクタル ) 入力パラメータの例 ( 小さな数値の変化で模様が大きく変化します. Ar や Ai の数値を少しずつ変化させて描画する. ) プログラムコード. 2010, AGU, M.

フラクタル 1 ( ジュリア集合 ) 解説 : ジュリア集合 ( 自己平方フラクタル ) 入力パラメータの例 ( 小さな数値の変化で模様が大きく変化します. Ar や Ai の数値を少しずつ変化させて描画する. ) プログラムコード. 2010, AGU, M. フラクタル 1 ( ジュリア集合 ) PictureBox 1 TextBox 1 TextBox 2 解説 : ジュリア集合 ( 自己平方フラクタル ) TextBox 3 複素平面 (= PictureBox1 ) 上の点 ( に対して, x, y) 初期値 ( 複素数 ) z x iy を決める. 0 k 1 z k 1 f ( z) z 2 k a 写像 ( 複素関数 ) (a : 複素定数

More information

Computer Net Revision

Computer Net Revision First:In the following Form window, if it is required to store entries from the user in variables. Define the corresponding Data Type for each input. 1. 2. 3. 4. 1 2 3 4 1- Less number of bytes means more

More information

超音波モータ制御プログラムの作成 (v1.2.1)

超音波モータ制御プログラムの作成 (v1.2.1) 超音波モータ制御プログラムの作成 (v1.2.1) 2008 年 11 月 28 日 Masaaki MATSUO 構成機器 モータ本体 : フコク ロータリーエンコーダー内蔵型超音波モータ USB-60E モータ制御部 : フコク 位置決制御ドライバ DCONT-3-60 (SD13) コントローラ : Interface 2 軸絶縁パルスモーションコントローラ ( 直線補間エンコーダ入力 5V)

More information

Running the Altair SIMH from.net programs

Running the Altair SIMH from.net programs Running the Altair SIMH from.net programs The Altair SIMH simulator can emulate a wide range of computers and one of its very useful features is that it can emulate a machine running 50 to 100 times faster

More information

System Analysis and Design

System Analysis and Design System Analysis and Design LAB RECORD-INFS -280/L Information Systems Department University of Nizwa, Sultanate of Oman Table of Contents Task. No: Title Page Nos. Date 1) VB Text box and Message Button

More information

Level 3 Computing Year 1 Lecturer: Phil Smith

Level 3 Computing Year 1 Lecturer: Phil Smith Level 3 Computing Year 1 Lecturer: Phil Smith Previously.. We looked at forms and controls. The event loop cycle. Triggers. Event handlers. Objectives for today.. 1. To gain knowledge and understanding

More information

Code: Write a Program for perform Money Conversion. Public Class Form1

Code: Write a Program for perform Money Conversion. Public Class Form1 Write a Program for perform Money Conversion. Code: Public Class Form1 Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click Dim a As Double a = TextBox1.Text

More information

ก Microsoft Visual Studio 2008

ก Microsoft Visual Studio 2008 ก 58 ก ก ก ก ก 58 59 ก Microsoft Visual Studio 2008 1. DVD ก MSVS2008 ก MSVS2008 ก ก MSVS2008 ก ก 180 DVD DVD ก MSVS2008 ก ก Install Visual Studio 2008 2. ก ก ก ก ก Next 3. ก ก Options Page ก Custom ก

More information

Computing Science Unit 1

Computing Science Unit 1 Computing Science Unit 1 Software Design and Development Programming Practical Tasks Business Information Technology and Enterprise Contents Input Validation Find Min Find Max Linear Search Count Occurrences

More information

VISUAL BASIC 2005 EXPRESS: NOW PLAYING

VISUAL BASIC 2005 EXPRESS: NOW PLAYING VISUAL BASIC 2005 EXPRESS: NOW PLAYING by Wallace Wang San Francisco ADVANCED DATA STRUCTURES: QUEUES, STACKS, AND HASH TABLES Using a Queue To provide greater flexibility in storing information, Visual

More information

variables programming statements

variables programming statements 1 VB PROGRAMMERS GUIDE LESSON 1 File: VbGuideL1.doc Date Started: May 24, 2002 Last Update: Dec 27, 2002 ISBN: 0-9730824-9-6 Version: 0.0 INTRODUCTION TO VB PROGRAMMING VB stands for Visual Basic. Visual

More information

Senior Software Engineering Project CSSP Project CEN April 5, Adam Cox Tass Oscar

Senior Software Engineering Project CSSP Project CEN April 5, Adam Cox Tass Oscar Senior Software Engineering Project CSSP Project CEN 4935 April 5, 2006 Adam Cox Tass Oscar 1. Introduction One of the ways in which social worker professionals and students evaluate their clients is with

More information

Learning VB.Net. Tutorial 15 Structures

Learning VB.Net. Tutorial 15 Structures Learning VB.Net Tutorial 15 Structures Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple applications, hope you enjoy it.

More information

To get started with Visual Basic 2005, I recommend that you jump right in

To get started with Visual Basic 2005, I recommend that you jump right in In This Chapter Chapter 1 Wading into Visual Basic Seeing where VB fits in with.net Writing your first Visual Basic 2005 program Exploiting the newfound power of VB To get started with Visual Basic 2005,

More information

C4.3, 4 Lab: Conditionals - Select Statement and Additional Input Controls Solutions

C4.3, 4 Lab: Conditionals - Select Statement and Additional Input Controls Solutions C4.3, 4 Lab: Conditionals - Select Statement and Additional Input Controls Solutions Between the comments included with the code and the code itself, you shouldn t have any problems understanding what

More information

Form Connection. Imports System Imports System.Threading Imports System.IO.Ports Imports System.ComponentModel

Form Connection. Imports System Imports System.Threading Imports System.IO.Ports Imports System.ComponentModel Form Connection Imports System Imports System.Threading Imports System.IO.Ports Imports System.ComponentModel Public Class connection '------------------------------------------------ Dim myport As Array

More information

IT3101 -Rapid Application Development Second Year- First Semester. Practical 01. Visual Basic.NET Environment.

IT3101 -Rapid Application Development Second Year- First Semester. Practical 01. Visual Basic.NET Environment. IT3101 -Rapid Application Development Second Year- First Semester Practical 01 Visual Basic.NET Environment. Main Area Menu bar Tool bar Run button Solution Explorer Toolbox Properties Window Q1) Creating

More information

VARIABLES. 1. STRINGS Data with letters and/or characters 2. INTEGERS Numbers without decimals 3. FLOATING POINT NUMBERS Numbers with decimals

VARIABLES. 1. STRINGS Data with letters and/or characters 2. INTEGERS Numbers without decimals 3. FLOATING POINT NUMBERS Numbers with decimals VARIABLES WHAT IS A VARIABLE? A variable is a storage location in the computer s memory, used for holding information while the program is running. The information that is stored in a variable may change,

More information

Apéndice E Código de software de ayuda en Visual Basic 2005 Public Class Form1

Apéndice E Código de software de ayuda en Visual Basic 2005 Public Class Form1 Apéndice E Código de software de ayuda en Visual Basic 2005 Public Class Form1 Dim checkcont As Integer = 0, foto = 0 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)

More information

Function: function procedures and sub procedures share the same characteristics, with

Function: function procedures and sub procedures share the same characteristics, with Function: function procedures and sub procedures share the same characteristics, with one important difference- function procedures return a value (e.g., give a value back) to the caller, whereas sub procedures

More information

Form Adapter Example. DRAFT Document ID : Form_Adapter.PDF Author : Michele Harris Version : 1.1 Date :

Form Adapter Example. DRAFT Document ID : Form_Adapter.PDF Author : Michele Harris Version : 1.1 Date : Form Adapter Example DRAFT Document ID : Form_Adapter.PDF Author : Michele Harris Version : 1.1 Date : 2009-06-19 Form_Adapter.doc DRAFT page 1 Table of Contents Creating Form_Adapter.vb... 2 Adding the

More information

1 Dept: CE.NET Programming ( ) Prof. Akash N. Siddhpura. Working with Form: properties, methods and events

1 Dept: CE.NET Programming ( ) Prof. Akash N. Siddhpura. Working with Form: properties, methods and events Working with Form: properties, methods and events To create a New Window Forms Application, Select File New Project. It will open one dialog box which is shown in Fig 2.1. Fig 2.1 The New Project dialog

More information

NOTES: Procedures (module 15)

NOTES: Procedures (module 15) Computer Science 110 NAME: NOTES: Procedures (module 15) Introduction to Procedures When you use a top-down, structured program design, you take a problem, analyze it to determine what the outcome should

More information

CALIFORNIA STATE UNIVERSITY, SACRAMENTO College of Business Administration. MIS 15 Introduction to Business Programming. Programming Assignment 3 (P3)

CALIFORNIA STATE UNIVERSITY, SACRAMENTO College of Business Administration. MIS 15 Introduction to Business Programming. Programming Assignment 3 (P3) CALIFORNIA STATE UNIVERSITY, SACRAMENTO College of Business Administration MIS 15 Introduction to Business Programming Programming Assignment 3 (P3) Points: 50 Due Date: Tuesday, May 10 The purpose of

More information

Unit 3. Lesson Designing User Interface-2. TreeView Control. TreeView Contol

Unit 3. Lesson Designing User Interface-2. TreeView Control. TreeView Contol Designing User Interface-2 Unit 3 Designing User Interface-2 Lesson 3.1-3 TreeView Control A TreeView control is designed to present a list in a hierarchical structure. It is similar to a directory listing.

More information

Interacting with External Applications

Interacting with External Applications Interacting with External Applications DLLs - dynamic linked libraries: Libraries of compiled procedures/functions that applications link to at run time DLL can be updated independently of apps using them

More information

Visual Basic.NET. 1. Which language is not a true object-oriented programming language?

Visual Basic.NET. 1. Which language is not a true object-oriented programming language? Visual Basic.NET Objective Type Questions 1. Which language is not a true object-oriented programming language? a.) VB.NET b.) VB 6 c.) C++ d.) Java Answer: b 2. A GUI: a.) uses buttons, menus, and icons.

More information

: CREATING WEB BASED APPLICATIONS FOR INSTRUMENT DATA TRANSFER USING VISUAL STUDIO.NET

: CREATING WEB BASED APPLICATIONS FOR INSTRUMENT DATA TRANSFER USING VISUAL STUDIO.NET 2006-938: CREATING WEB BASED APPLICATIONS FOR INSTRUMENT DATA TRANSFER USING VISUAL STUDIO.NET David Hergert, Miami University American Society for Engineering Education, 2006 Page 11.371.1 Creating Web

More information

โปรแกรมช วยทดสอบหม อแปลงกระแส

โปรแกรมช วยทดสอบหม อแปลงกระแส โปรแกรมช วยทดสอบหม อแปลงกระแส 1.เมน ของโปรแกรม ภาพท 1 หน าเมน ของโปรแกรม Public Class frmmain Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

More information

HOUR 4 Understanding Events

HOUR 4 Understanding Events HOUR 4 Understanding Events It s fairly easy to produce an attractive interface for an application using Visual Basic.NET s integrated design tools. You can create beautiful forms that have buttons to

More information

Connection Example. Document ID : Connection_Example.PDF Author : Michele Harris Version : 1.1 Date :

Connection Example. Document ID : Connection_Example.PDF Author : Michele Harris Version : 1.1 Date : Connection Example Document ID : Connection_Example.PDF Author : Michele Harris Version : 1.1 Date : 2009-06-19 page 1 Table of Contents Connection Example... 2 Adding the Code... 2 Quick Watch myconnection...

More information

REVIEW OF CHAPTER 1 1

REVIEW OF CHAPTER 1 1 1 REVIEW OF CHAPTER 1 Trouble installing/accessing Visual Studio? 2 Computer a device that can perform calculations and make logical decisions much faster than humans can Computer programs a sequence of

More information

Overview About KBasic

Overview About KBasic Overview About KBasic The following chapter has been used from Wikipedia entry about BASIC and is licensed under the GNU Free Documentation License. Table of Contents Object-Oriented...2 Event-Driven...2

More information

The Filter Property Selecting a File The Save Menu The SaveFileDialog Control The Edit Menu The Copy Menu...

The Filter Property Selecting a File The Save Menu The SaveFileDialog Control The Edit Menu The Copy Menu... Part One Contents Introduction...3 What you need to do the course...3 The Free Visual Basic Express Edition...3 Additional Files...4 Getting Started...5 The Toolbox...9 Properties...15 Saving your work...21

More information

SAULT COLLEGE OF APPLIED ARTS & TECHNOLOGY SAULT STE MARIE, ON COURSE OUTLINE

SAULT COLLEGE OF APPLIED ARTS & TECHNOLOGY SAULT STE MARIE, ON COURSE OUTLINE SAULT COLLEGE OF APPLIED ARTS & TECHNOLOGY SAULT STE MARIE, ON COURSE OUTLINE Course Title: Introduction to Visual Basic Code No.: Semester: Three Program: Computer Programming Author: Willem de Bruyne

More information

Getting Started with Visual Basic.NET

Getting Started with Visual Basic.NET Visual Basic.NET Programming for Beginners This Home and Learn computer course is an introduction to Visual Basic.NET programming for beginners. This course assumes that you have no programming experience

More information

KULLEĠĠ SAN BENEDITTU Secondary School, Kirkop

KULLEĠĠ SAN BENEDITTU Secondary School, Kirkop KULLEĠĠ SAN BENEDITTU Secondary School, Kirkop Mark HALF YEARLY EXAMINATION 2014/2015 Level 5 6 7-8 Form 4 COMPUTING TIME: 1h 30min Question 1 2 3 4 5 6 7 8 9 Global Mark Max. Mark 8 5 7 10 8 12 13 16

More information

Learning VB.Net. Tutorial 16 Modules

Learning VB.Net. Tutorial 16 Modules Learning VB.Net Tutorial 16 Modules Hello everyone welcome to vb.net tutorials. These are going to be very basic tutorials about using the language to create simple applications, hope you enjoy it. If

More information

Visual Basic 2008 The programming part

Visual Basic 2008 The programming part Visual Basic 2008 The programming part Code Computer applications are built by giving instructions to the computer. In programming, the instructions are called statements, and all of the statements that

More information

Departme and. Computer. CS Intro to. Science with. Objectives: The main. for a problem. of Programming. Syntax Set of rules Similar to.

Departme and. Computer. CS Intro to. Science with. Objectives: The main. for a problem. of Programming. Syntax Set of rules Similar to. _ Unit 2: Visual Basic.NET, pages 1 of 13 Departme ent of Computer and Mathematical Sciences CS 1408 Intro to Computer Science with Visual Basic.NET 4 Lab 4: Getting Started with Visual Basic.NET Programming

More information

ISM 3253 Exam I Spring 2009

ISM 3253 Exam I Spring 2009 ISM 3253 Exam I Spring 2009 Directions: You have exactly 75 minutes to complete this test. Time available is part of the exam conditions and all work must cease when "Stop work" is announced. Failing to

More information

Lookup Project. frmlookup (Name: object is a combo box, style 2); use 4 labels: 2 for phone, 2 for mail. MsgBox Function:

Lookup Project. frmlookup (Name: object is a combo box, style 2); use 4 labels: 2 for phone, 2 for mail. MsgBox Function: Lookup Project frmlookup (Name: object is a combo box, style 2); use 4 labels: 2 for phone, 2 for mail. MsgBox Function: Help About, in a Message Box lookup.vbp programmed by C.Gribble Page 2 Code for

More information

Repetition Structures

Repetition Structures Repetition Structures There are three main structures used in programming: sequential, decision and repetition structures. Sequential structures follow one line of code after another. Decision structures

More information

Level 3 Computing Year 2 Lecturer: Phil Smith

Level 3 Computing Year 2 Lecturer: Phil Smith Level 3 Computing Year 2 Lecturer: Phil Smith Previously We started to build a GUI program using visual studio 2010 and vb.net. We have a form designed. We have started to write the code to provided the

More information

VB.NET Programs. ADO.NET (insert, update, view records)

VB.NET Programs. ADO.NET (insert, update, view records) ADO.NET (insert, update, view records) VB.NET Programs Database: Student Table : Studtab (adno, name, age, place) Controls: DataGridView, Insert button, View button, Update button, TextBox1 (for Admission

More information

VBScript: Math Functions

VBScript: Math Functions C h a p t e r 3 VBScript: Math Functions In this chapter, you will learn how to use the following VBScript functions to World Class standards: 1. Writing Math Equations in VBScripts 2. Beginning a New

More information

VB FUNCTIONS AND OPERATORS

VB FUNCTIONS AND OPERATORS VB FUNCTIONS AND OPERATORS In der to compute inputs from users and generate results, we need to use various mathematical operats. In Visual Basic, other than the addition (+) and subtraction (-), the symbols

More information

I101/B100 Problem Solving with Computers

I101/B100 Problem Solving with Computers I101/B100 Problem Solving with Computers By: Dr. Hossein Hakimzadeh Computer Science and Informatics IU South Bend 1 What is Visual Basic.Net Visual Basic.Net is the latest reincarnation of Basic language.

More information

An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is

An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is InputBox( ) Function An InputBox( ) function will display an input Box window where the user can enter a value or a text. The format is A = InputBox ( Question or Phrase, Window Title, ) Example1: Integer:

More information

UNIT 2 USING VB TO EXPAND OUR KNOWLEDGE OF PROGRAMMING

UNIT 2 USING VB TO EXPAND OUR KNOWLEDGE OF PROGRAMMING UNIT 2 USING VB TO EXPAND OUR KNOWLEDGE OF PROGRAMMING UNIT 2 USING VB TO EXPAND OUR KNOWLEDGE OF PROGRAMMING... 1 IMPORTANT PROGRAMMING TERMINOLOGY AND CONCEPTS... 2 Program... 2 Programming Language...

More information

Design Of Human Computer Interfaces Assignment 1- Hello World. Compliance Report

Design Of Human Computer Interfaces Assignment 1- Hello World. Compliance Report Design Of Human Computer Interfaces Assignment 1- Hello World Compliance Report Prepared for: Skip Poehlman Prepared By: K C Course: SE 4D03 Date: September 30, 2008 Contents 1. Code Listing a. Module

More information

Lab Sheet 4.doc. Visual Basic. Lab Sheet 4: Non Object-Oriented Programming Practice

Lab Sheet 4.doc. Visual Basic. Lab Sheet 4: Non Object-Oriented Programming Practice Visual Basic Lab Sheet 4: Non Object-Oriented Programming Practice This lab sheet builds on the basic programming you have done so far, bringing elements of file handling, data structuring and information

More information

UNIT 1: PROGRAMMING ENVIRONMENT

UNIT 1: PROGRAMMING ENVIRONMENT UNIT 1: PROGRAMMING ENVIRONMENT 1.1 Introduction This unit introduces the programming environment for the Basic Digital Signal Processing course. It gives a brief description of the Visual Basic classes

More information

Upgrading Applications

Upgrading Applications C0561587x.fm Page 77 Thursday, November 15, 2001 2:37 PM Part II Upgrading Applications 5 Your First Upgrade 79 6 Common Tasks in Visual Basic.NET 101 7 Upgrading Wizard Ins and Outs 117 8 Errors, Warnings,

More information

Visual Studio.NET for AutoCAD Programmers

Visual Studio.NET for AutoCAD Programmers December 2-5, 2003 MGM Grand Hotel Las Vegas Visual Studio.NET for AutoCAD Programmers Speaker Name: Andrew G. Roe, P.E. Class Code: CP32-3 Class Description: In this class, we'll introduce the Visual

More information

How to Validate DataGridView Input

How to Validate DataGridView Input How to Validate DataGridView Input This example explains how to use DR.net to set validation criteria for a DataGridView control on a Visual Studio.NET form. Why You Should Use This To add extensible and

More information

Private Sub Cours_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

Private Sub Cours_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Public Class Cours Private nc As Integer Private Sub Cours_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'TODO : cette ligne de code charge les données dans la table

More information

STUDENT SOLUTIONS MANUAL

STUDENT SOLUTIONS MANUAL Student Solutions Manual (Page 1 of 211) STUDENT SOLUTIONS MANUAL to accompany An Introduction to Programming Using Visual Basic 2010, 8th Edition by David I. Schneider Student Solutions Manual (Page 2

More information

Test 1 October 19, 2007

Test 1 October 19, 2007 Name:, (last) (first) Student Number: Section: _A Instructor: P. Cribb York University aculty of Science and Engineering Department of Computer Science and Engineering COSC1530.03 - Introduction to Computer

More information

Introduction. Getting Started with Visual Basic Steps:-

Introduction. Getting Started with Visual Basic Steps:- Introduction Getting Started with Visual Basic 2008 Steps:- 1. go to http://www.microsoft.com/express/download/#webinstall and download Visual Basic 2008 and save the file in a location. 2. Locate the

More information

Chapter 2 Visual Basic, Controls, and Events. 2.1 An Introduction to Visual Basic 2.2 Visual Basic Controls 2.3 Visual Basic Events

Chapter 2 Visual Basic, Controls, and Events. 2.1 An Introduction to Visual Basic 2.2 Visual Basic Controls 2.3 Visual Basic Events Chapter 2 Visual Basic, Controls, and Events 2.1 An Introduction to Visual Basic 2.2 Visual Basic Controls 2.3 Visual Basic Events 1 2.1 An Introduction to Visual Basic 2010 Why Windows and Why Visual

More information

Seat No. Total No. of Questions : 6] [Total No. of Printed Pages : 2 [4189]-101. P. G. D. C. M. (Semester - I) Examination

Seat No. Total No. of Questions : 6] [Total No. of Printed Pages : 2 [4189]-101. P. G. D. C. M. (Semester - I) Examination Seat No. Total No. of Questions : 6] [Total No. of Printed Pages : 2 [4189]-101 P. G. D. C. M. (Semester - I) Examination - 2012 ELEMENTS OF INFORMATION TECHNOLOGY AND OFFICE AUTOMATION (2008 Pattern)

More information

An overview about DroidBasic For Android

An overview about DroidBasic For Android An overview about DroidBasic For Android from February 25, 2013 Contents An overview about DroidBasic For Android...1 Object-Oriented...2 Event-Driven...2 DroidBasic Framework...2 The Integrated Development

More information

Unit 4 Advanced Features of VB.Net

Unit 4 Advanced Features of VB.Net Dialog Boxes There are many built-in dialog boxes to be used in Windows forms for various tasks like opening and saving files, printing a page, providing choices for colors, fonts, page setup, etc., to

More information

Building Windows Applications

Building Windows Applications Summary of Contents Introduction 1 Chapter 1: Welcome to Visual Basic.NET 9 Chapter 2: Writing Software 41 Chapter 3: Controlling the Flow 97 Chapter 4: Building Objects 145 Chapter 5: The Microsoft.NET

More information