Updating a record in MS Access using Visual Basic

Update record

Update record

Updating a record in MS Access using Visual Basic

Welcome to our next tutorial in Visual Basic. This tutorial will teach us the procedures on how to update a record in MS Access.

This is the continuation of our previous tutorial which is Inserting a record in MS Access database.

Let’s do first a checklist:

  1. Connect Visual Basic to MS Access – we have already performed that, just in case you have missed the lesson kindly visit the page. (How to connect Visual Basic to MS Access)
  2. Insert a record in MS Access through Visual Basic – we have done on this part.

Progress Bar demo in Visual Basic 6

Progress Bar Demo

Progress Bar Demo

This tutorial will teach us on how to create a progress bar in Visual Basic 6

Kindly follow the step by step tutorial on creating a progress bar in visual basic 6

1. Open your visual basic 6. Create a new project and select Standard EXE.

2. By default there is only one Form (Form1). Rename the Form1 into ProgressBarFrm.

3. Before we create a progress bar, we must include Microsoft Windows Common Controls 5.0.

4. To include that component kindly go to Project in the menu bar and select Components.

Insert record in MS Access using Visual Basic

Insert Record

Insert Record

In our previous tutorial, we have discussed the step by step procedure on how to connect visual basic to ms access. This time we’re going to learn how to insert a record in our database.

We will provide you the step by step procedure on how to do that and source code will be provided for your reference.

Since this is the continuation of the previous project, kindly download the source code of the previous tutorial. (How to connect Visual Basic to MS Access).

After you have downloaded the source code, kindly follow the instructions below:

1. Open the database (Data.mdb) and create a new table (in the menu, select Create and click the Table icon).

2. Save the table as tblStudent and enter the following field:

How to connect Visual Basic to MS Access

This tutorial will guide you to connect your visual basic 6 to ms access database for you to develop a database application in visual basic.

What we need?

In this tutorial we need ms access database (2000-2003 format) (.mdb), a Visual basic form and a Module

1. Create an ms access database and save it as Data.mdb

2. Kindly open your visual basic 6 program.

3. On the file menu, select New Project and select Standard Exe.

4. By default there is only one Form (Form1).

Java while and the do while loop statements

The while and the do while statements in Java Programming.

We will introduce you to other types of looping statement in Java (while and do while loop).

while loop

while loop is a control structure in Java that executes a block of statements while a condition is true.

Here’s the structure or general format of writing a while loop:

while(condition)
{
loopBody        // yourJavaStatements
}

Java Programming for loop statement

Hi there! This next lesson will be on understanding for loop in Java Programming.

The for loop statement

This type of loop will repeat Java statements for a specific number of times.

forLoop

 

 

 

 

 

Learning Switch Statement in Java Programming

Welcome to our next Java lesson and in this lesson we are going to learn about the switch statement.

What is a switch statement?

A switch statement is just like if else if statement the difference is that there is only one expression/variable to be tested in switch statement.

Here’s the syntax of the switch statement:

switch (variableToTest) {

  case Value1:

        statement(s) to be executed if  variableToTest = Value1;
        break;

  case Value2:

        statement(s) to be executed if  variableToTest = Value2;
        break;

  case Value3:

        statement(s) to be executed if  variableToTest = Value3;
        break;

  default:

        statement(s) to be executed if  all cases did not match the variableToTest;
        break;

}

Java If, If Else, If Else If Statement

Java If, If Else, If Else If Statement

This Lesson will teach us one of the control flow statements in Java programming: the if statement.

Just like every other programming language the if statement in Java is one way form of incorporating decision making on our program.

if statement (the one way selection)

This statement is used to test if the expression is true. In order for the action statement to be executed the expression must return true, otherwise the program will do nothing.

Comments in Java Programming

In this Java tutorial, we are going to learn about creating comments.

Comments in programming do not change the functionality or how your program works but it plays an important role in documentation of your program.

There are 3 types of comments in Java Programming (single line comment, multi line comment and documentation comment).

Java Lesson about Variables

Hi everyone, welcome to our next lesson in Java.

This lesson is about variables in Java. We will learn the following in this lesson:

  • Naming convention of variables in Java
  • How to declare a variable
  • How to initialize and assign value to a variable

A variable is a storage location that has a value or content and may change the value during the execution of program.

Naming convention

Every programming language has its own rules on how to name your variable. Here’s the rule of Java for naming variables.