Monday, July 23, 2018

Fransiskus Sutris

MYSQL CRUD Using Custom Function In VB.Net (Part 3)

Step 2Back - Create Function For Insert, Update And Delete Data

Step 3: Testing The Function in Form1


  • Create Database exercise1
Create database on mysql. You can execute query below in your mysql management database :



  • Design Form1, Please design form like picture below:

  • Copy And Paste code below to your form1 code:


  • Run your project by press F5
  • You can test input and save data
Read More
Fransiskus Sutris

MYSQL CRUD Using Custom Function In VB.Net (Part 2)

Step 1: Create Function Connection to Database
Step 2: Create Function For Insert, Update And Delete Data

In Step 2 we will create function for insert, update and delete data from database.

  • Function For Insert Data

  • Function For Update Data



  • Function For Delete Data


Step 3: Next - Testing The Function In Form1
Read More
Fransiskus Sutris

MYSQL CRUD Using Custom Function In VB.Net

In this article I will share my way to Mysql CRUD using vb.net by creating custom functions. Why custom function, because this function I created itself to simplify and shorten the program to CRUD data from the database by calling the function. So we no longer need to type the insert, update and delete commands in the sql query.

Step 1: Create Function For Connect To Database

  • Open Visual Basic .Net
  • Create New Project
  • Add New Module (Right click on Project Name at Solution Explorer - Add - Module)
  • Let its name Module1.vb
  • Add to Reference : MySql.Data.Dll

Type codes below to Module1:



Step 2: Next - Create Function For Insert, Update And Delete Data
Read More