Presentation is loading. Please wait.

Presentation is loading. Please wait.

Creating Embedded Formative Assessment Dr. Steve Broskoske Misericordia University EDU 533 Computer-based Education.

Similar presentations


Presentation on theme: "Creating Embedded Formative Assessment Dr. Steve Broskoske Misericordia University EDU 533 Computer-based Education."— Presentation transcript:

1 Creating Embedded Formative Assessment Dr. Steve Broskoske Misericordia University EDU 533 Computer-based Education

2 Outline Review of Variables Personalizing CBT –New object: InputBox Creating embedded assessment with variables –Providing feedback with MsgBox –Counting variable Working with conditional statements –Advanced MsgBox properties –Navigating

3 Review of Variables

4 What is a Variable? variable: Named location in program code for storing data. Analogous to the memory function on a calculator. A variable in VBA is like saying in Algebra: x = 5 OR x = “Dr. Steve” Review

5 Declare a Variable To use a variable, start by declaring it with a dim statement. –Dim variable_name As data_type Make up a name for a variable. Use underscore (_) for compound names. Variable types are either text (string) or a numerical type. Review long single Boolean string

6 Local vs. Public Variables Where a variable is declared affects how it functions. –public variable: A variable that is declared as public is “alive” and available to all subroutines throughout the project. Declare a public variable at the top of the form. –private variable: A variable that is declared within one subroutine is “alive” only as long as the subroutine is running. Declare a private variable within one subroutine. Review

7 Concatenation with Strings –Add additional strings to a string variable. Dim age As Integer, maxcount As Integer Dim sentence As string age = 5 maxcount = 100 sentence = “I am ” & age & “years old.” sentence = sentence & “I can count to ” & maxcount Review

8 Do Not Duplicate Names As you create names for procedures and variables, be careful not to: –Name 2 procedures by the same name. –Name 2 variables by the same name. –Name a procedure the same as a variable, or vice versa. Review

9 Personalizing CBT with an InputBox and a Variable

10 VBA allows teachers to personalize the application. Let’s write the following procedures: –Remember user name (stores name in a variable). In the process, let’s compare local vs. public variables. –Prompt a user to enter his/her name. New object: InputBox.

11 Elements We Need Sub Name() scripting goes here End Sub Dim userName As String –Place within procedure to create local. –Place on top of form to create public. userName = “Dr. Steve” 'Comments after quote. MsgBox ("Your user name is " & userName) –Must concatenate new text and a string variable.

12 New Object InputBox: Prompts user to enter something. Entered material must be stored in a variable. Syntax: Variable = InputBox(Prompt:=“text”, Title:=“title bar text”)

13 TRY IT 1.enterUserName() 2.printName() Enter User Name Print name using MsgBox

14 TRY IT 1.Have students enter name using a public variable (you already scripted this code; reuse this macro). 2.Create personalized student feedback. Give Personalized Positive Feedback Enter Name Using Public Variable (Use VBA already created.)

15 TRY IT enterUserName() [Reuse this code. Realize that if this PP was one continuously running application, we would not have to prompt user to enter name again. The variable would already contain in.] enterAge() enterBooksRead() printNameAgeBooks() [Use a MsgBox to print out personalized information.] Enter Name (reuse code) Enter AgeEnter Books Read Print Name, Age, Books in a Personalized Way

16 Creating Embedded Assessment with Variables

17 Importance of Embedded Assessment In CBT, we want to have: –Make learners interact vs. just passively read. –Rehearse small chunk of material already learned. In a live classroom, teachers don’t simply teach at students. We provide examples, ask questions, review important items, and provide opportunities to rehearse and apply material.

18 Providing Feedback with Standard PP Tools Pick the farm animal that gives us milk. Remember that graphics and even text boxes can have action settings applied. You could use buttons here in place of graphics.

19 Feedback Screen INCORRECT. Please try again. Try Again

20 Feedback Screen CORRECT. A cow provides milk. Good job! Continue

21 Providing Feedback with VBA With VBA, we can provide feedback by using MsgBoxes. If we create a standard message, we can simply call the same procedure at different times without having to do extra work.

22 Providing Feedback with VBA enterUserName() [You already created this code. Just use what you already made.] doingWell() doingPoorly() Enter User Name (reuse code) Correct Response Incorrect Response

23 Providing Feedback with VBA You can now call these procedures from another slide. (Start the show from the previous slide so the student’s name will be available.) b. c. a. This is an INCORRECT response to this item. This is the CORRECT response to this item. This is an INCORRECT response to this item.

24 Adding a Counting Variable You can add a counting variable to keep track of how many times a student has taken to locate the correct response. Dim tries As Integer tries = tries + 1

25 Adding a Counting Variable Declare a public variable to keep track of tries. Simply increment the counter in each procedure. Later, we can take some action depending on the number of tries taken. (Requires more code.) –Note: It’s a good practice to initialize variables. We’ll look at this shortly. b. c. a. INCORRECT response to this item. CORRECT response to this item. INCORRECT response to this item. Show Number of Tries to Teacher

26 Working with Conditional Statements

27 Conditional Statements Much of the power that VBA adds to PP is the capacity to make decisions based on student input. We can evaluate student input/responses and then make decisions and take actions.

28 Conditional Statements Syntax for a conditional statement: If condition Then coding Else coding End If

29 Conditional Statements If tries>2 Then MsgBox(“Statement”) Else MsgBox(“Statement”) End If If overLimit=false Then code to do something Else code to do something End If

30 TRY IT Reapply macros already created to this slide. displayProgress() –If tries is less than 3, then give positive feedback in a MsgBox. –If tries is anything else (meaning greater than 3), give a comment that the student needs improvement. b. c. a. INCORRECT response to this item. CORRECT response to this item. INCORRECT response to this item. Review Progress

31 If Statement with Advanced MsgBox You can customize the buttons displayed in a message box to help gather user input. (MsgBox now functions like a simple InputBox.) If you add an “IF…THEN” statement to evaluate this user input, you can then have more powerful decision-making at your disposal.

32 Making Decision with Message Boxes Displayed button options: –MsgBox(“question”, vbYesNo) –MsgBox(“question”, vbRetryCancel) Just as with an InputBox, let a variable equal the input. The variable will contain “yes” or “no” or “retry” or “cancel”.

33 Making Decision with Message Boxes Dim readyOrNot 'Does not need type: constant. readyOrNot = MsgBox(“Are you ready to try the assessment?”, vbYesNo) If readyOrNot = yes Then MsgBox(“Good. You are prepared.”) Else MsgBox(“Sorry you do not feel ready.”) End If

34 TRY IT finishedWithHomework() –Create a variable homeworkDone to hold user input from the constant from vbYesNo in a MsgBox. –Give feedback with MsgBox using If…Then. Answer a Question

35 Navigating Action settings allow you to navigate to a specified slide. With VBA and conditional statements (If…Then), you can control where a student navigates next. Syntax: ActivePresentation.SlideShowWindow.View. –GotoSlide (num) –Next –Previous

36 TRY IT Navigate to the next slide Navigate to the previous slide Navigate to a numbered slide

37 TRY IT Question 3: IncorrectCorrect Direct User based on answer

38 Assignments

39 Assignment 1.Using VBA, create a brief assessment in PP with the following parameters: –3 questions (items) –Each item can have 2 possible responses. a b Possible answer number 1. Possible answer number 2.

40 Assignment On the first slide, use an input box to enter the learner’s name in a public variable. When the user clicks a response: –Navigate to the next slide to view the next question. –Increment a public variable that keeps track of how many questions the learner answered correctly.

41 Assignment On the last slide, create a button that provides personalized input: –Use a message box to display information. –List user’s name. –Display number of corrections that the user got correct.

42 Next Week Working with object properties. More advanced work with variables. Looping.


Download ppt "Creating Embedded Formative Assessment Dr. Steve Broskoske Misericordia University EDU 533 Computer-based Education."

Similar presentations


Ads by Google