Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 62

ACKNOWLEGDEMENT

The success and final outcome of this project required a lot of


guidance and assistance from many people and I am extremely
privileged to have got this all along the completion of my project. All
that I have done is only due to such supervision and assistance and I
would not forget to thank them.

I respect and thank Prof. Ramakrishna Murali, principal of ASC


Degree College for providing me an opportunity to do the project
work in Mindset IT Solution and giving us all support and guidance
which made me complete the project duly. I am extremely thankful
to Prof. Smita Girish, HOD of BCA Department for providing such a
nice support and guidance.

I owe my deep gratitude to our project guide Prof. Vibha Gururaj,


who took keen interest on our project work and guided us all along,
till the completion of our project work by providing all the necessary
information for developing a good system.

CAR INVENTORY MANAGEMENT 2017

CONTENTS
CHAPTERS PAGE NO

1.INTRODUCTION
Abstract of the project
2.SOFTWARE REQUIREMENT SPECIFICATION
2.1 Hardware Requirements
2.2 Software Requirements
2.3 System Analysis
2.4 Existing System
2.5 Proposed System
3.SYSTEM DESIGN
3.1 Introduction
3.2 Input Design
3.3 Output Design
3.4 Data Flow Diagram
CAR INVENTORY MANAGEMENT

3.5 E-R Diagram


4.IMPLMENTATION DETAILS
4.1 About Front End
4.2 About Back End
5.DATA STRUCTURE
6.NORMALIZATION
7.CODING
7.1 Coding
7.2 Output Screens
8.FUTURE ENHANCEMENT
9.CONCLUSION
10.BIBLIOGRAPHY
CAR INVENTORY MANAGEMENT

ABSTRACT
CAR INVENTORY MANGEMENT

ABSTRACT
The main objective of this system is to keep records of the
complete inventory. It support for inventory management helps
you record and track materials on the basis of both quantity and
value. It improves cash flow, visibility, and decision making. For
warehouse management, you can track quantity and value of all your
materials, perform physical inventory, and optimize your warehouse
resources.

CAR INVENTORY MANAGEMENT


SOFTWARE
REQUIREMENT
SPECIFICATION

CAR INVENTORY MANAGEMENT


HARDWARE SOFTWARE REQUIRMENTS

SOFTWARE REQUIREMENT
Operating System: Windows 10

Front End: VB.NET

Back End: SQL SERVER

Languages Used: VB.NET, SQL

HARDWARE REQUIREMENT
Ram:

Hard disk: 1tb

Speed: 1600 MHz

Cache Memory: 3mb

CAR INVENTORY MANAGEMENT


SYSTEM ANALYSIS
System analysis is a process of gathering and interpreting facts,
diagnosing problems and the information to recommend
improvements on the system. System analysis is an important phase
of any system development process. The system is viewed as a whole
and the input to the system are identified. The outputs from the
organizations are traced to the various processes. System analysis is
concerned with becoming aware of the problem, identifying the
relevant and decisional variables, analyzing and synthesizing the
various factors and determining an optimal or at least a satisfactory
solution or program of action.

A detailed study of process much be made by various techniques


like interviews, questionnaires etc. The data collected by these
sources must be scrutinized to arrive to a conclusion. The conclusion
is an understanding of how the system functions. This system is
called existing system. Now the existing system is subjected to close
study and problem are identified. The designer now functions as a
problem solver and tries to sort out the difficulties that the
enterprise faces.
CAR INVENTORY MANAGEMENT

EXISTING SYSTEM
As we know the manual processing is quite tedious, time
consuming, less accurate in comparison to computerized processing.
Obviously the present system is not is exception consultant
encountering all the below problems.

1. Time consuming.

2. It is very tedious.

3. All information is not placed separately.

4. Lot of paper work.

5. Slow data processing.

6. Not user-friendly environment.

7. It is difficult to found records due file management system.


CAR INVENTORY MANAGEMENT

PROPOSED SYSTEM
The scope of this system is to provide user efficient working
environment and more output can be generated through this. This
system provides user friendly interface resulting in knowing each and
every usability features of the system. This system helps in tracking
records so that past records can be verified through them and one
can make decisions based on the past records. This system
completes the work in a very less time resulting in less time
consumption and high level of efficiency.

This system is developed in such a way that even a naïve user can
also operate the system easily. The calculations are made very
quickly and the records are directly saved into databases and the
databases can be maintained for a longer period of time. Each record
can be retrieved and can be verified for the future transactions .

Also this system provides high level of security for data leaking as
only admin people can access the database no changes can be made
in it until it verifies the user login id and password.

We also have operator login through which operator can take orders
but can’t make changes in the database. Limited access is available
to the operator.
CAR INVENTORY MANAGEMENT

ADVANTAGES:
 Minimize manual data entry.
 Minimum time needed for the various processing.
 Greater efficiency.
 Better service.
 User friendliness and interactive.
 Minimum time required.
CAR INVENTORY MANAGEMENT

SYSTEM DESIGN
CAR INVENTORY MANAGEMENT

SYSTEM DESIGN
INTRODUCTION
Systems design (also called systems synthesis) is a
complementary problem-solving technique (to systems
analysis) that reassembles a system’s component pieces back
into a complete system—hopefully, an improved system. This
may involves adding, deleting, and changing pieces relative to
the original system.

INPUT DESIGN
The input design is the link between the information system
and the user. It comprises the developing specification and
procedures for data preparation and those steps are
necessary to put transaction data into a usable form for
processing can be achieved by inspecting the computer to
read data from a written or printed document or it can occur
by having people keying the data directly into the system.
The design of input focuses on controlling the amount of
input required, controlling the errors, avoiding delay,
avoiding extra steps and keeping the process simple. The
input is designed in such a way so that it provides security
CAR INVEMTORY MANAGEMENT

and ease of use with retaining the privacy. Input Design


considered the following things:
 What data should be given as input?
 How the data should be arranged or coded?
 Methods for preparing input validations and steps to
follow when error occur.

OUTPUT DESIGN
A quality output is one, which meets the requirements of
the end user and presents the information clearly. In any
system results of processing are communicated to the users
and to other system through outputs. In output design it is
determined how the information is to be displaced for
immediate need and also the hard copy output. It is the most
important and direct source information to the user. Efficient
and intelligent output design improves the system's
relationship to help user decision-making.
Designing computer output should proceed in an organized,
well thought out manner; the right output must be
developed while ensuring that each output element is
designed so that people will find the system can use easily
and effectively. When analysis design computer output, they
CAR INNVENTORY MANAGEMENT

Should identify the specific output that is needed to meet


the requirements.
 Select methods for presenting information.
 Create document, report, or other formats that contain
information produced by the system.
 Database Design.
CAR INVENTORY MANAGEMENT

DATA FLOW
DIAGRAM
CAR INVENTORY MANAGEMENT

INTRODUCTION TO DATA FLOW DIAGRAM


INTRODUCTION
Data-flow design is concerned with designing a sequence of
functional transformations that convert systems inputs into
the required outputs. The design is represented as data-flow
diagrams. These diagrams illustrate how data flows through a
system and how the output is derived from the input through
a sequence of function transformations.
Data-flow diagrams are a useful and intuitive way of
describing a system. They are normally understandable
without special training, especially if control information is
excluded. They show end-to-end processing. That is, the flow
of processing from when data enters the system to where it
leaves the system can be traced.
Data-flow design is an integral part of a number of design
methods and most CASE tools to support data-flow diagram
creation.
Different methods may use different icons to represent data-
flow diagram entities but their meanings are similar.
CAR INVENTORY MANAGENMENT

DATA FLOW DIAGRAM SYMBOL


SYMBOL NAME MEANING

Represents data stores. They should


be given a descriptive name.
Rectangle

Represents functions which transform


inputs to outputs. The transformation
Rounded Rectangle name indicates its function.

It shows the direction of data. Their


name describes the data flowing along
Arrows that path.

Represents user interactions with the


systems that provide input or receive
Circle output.
CAR INVENTORY MANAGEMENT SYSYEM

Login

Admin

Car Inventory
Management
CAR INVENTORY MANAGEMENT SYSYEM

Login

Car Inventory Management

Admin

0
Master entry

Car details entry

Purchase entry

Sales

Stock report

Reports
CAR INVENTORY MANAGEMENT SYSYEM
CAR INVENTORY MANAGEMENT SYSYEM

INTRODUCTION TO ER DIAGRAM
Introduction
The graphical representation of organizational system
elements and the association among the elements is called
ER Diagram.
 The elements that make up a system are referred to as
entities.
 A relationship is the association that describes the
interaction between entities.
 An ER diagram also may indicate the cardinality of a
relationship.
 The ER notation also allows for distinguishing different
types of entities.
 The database designer creates an entity-relationship (E-
R) diagram to show the entities for which information
needs to be stored and the relationship between those
entities.
CAR INVENTORY MANAGEMENT SYSYEM

E-R DIAGRAM SYMBOLS


SYMBOL MEANING

Entity

Weak entity

Relationship

Identifying relationship

Attribute

Key attribute

Multivalued attribute
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT

IMPLEMENTATION
CAR INVENTORY MANAGEMENT

INTRODUCTION TO VB.NET
What is .NET?
Microsoft announced its .NET initiative in 2000. .NET encompasses a
series of technologies that allows almost any type of application to
run in a common environment. Visual Studio .NET, which includes
Visual Basic .NET, is the first major set of tools available that allow
for many applications to be created for .NET. The common
environment in which applications created for .NET run is known
as .NET Framework.

Visual Basic .NET (VB.NET) is an object-oriented computer


programming language implemented on the .NET Framework.
Although it is an evolution of classic Visual Basic language, it is not
backwards-compatible with VB6, and any code written in the old
version does not compile under VB.NET.

Like all other .NET languages, VB.NET has complete support for
object-oriented concepts. Everything in VB.NET is an object,
including all of the primitive types (Short, Integer, Long, String,
Boolean, etc.) and user-defined types, events, and even assemblies.
All objects inherit from the base class Object.

VB.NET is implemented by Microsoft's .NET framework. Therefore, it


has full access to all the libraries in the .Net Framework. It's also
possible to run VB.NET programs on Mono, the open-source
alternative to .NET, not only under windows, but even LINUX or MAC
OSX.

CAR INVENTORY MANAGEMENT

The following reasons make VB.Net a widely used professional


language:

• Modern, general purpose.

• Object oriented.

• Component oriented.

• Easy to learn.

• Structured language.

• It produces efficient programs.

• It can be compiled on a variety of computer platforms.

• Part of .Net Framework.

• Strong Programming Features VB.Net

VB.Net has numerous strong programming features that make it


endearing to multitude of programmers worldwide. Let us mention
some of these features:

• Boolean Condition

• Automatic Garbage Collection

• Standard Library
• Assembly Versioning

• Properties and Events

CAR INVENTORY MANAGEMENT

• Delegates and Events Management

• Easy-to-use Generics

• Indexers

• Conditional Compilation

• Simple Multithreading

VB.Net is an object-oriented programming language. In Object-


Oriented Programming methodology, a program consists of various
objects that interact with each other by means of actions. The
actions that an object may take are called methods. Objects of the
same kind are said to have the same type or, more often, are said to
be in the same class.

When we consider a VB.Net program, it can be defined as a


collection of objects that communicate via invoking each other's
methods. Let us now briefly look into what do class, object, methods
and instance variables mean.

Object - Objects have states and behaviors. Example: A dog has


states - color, name, breed as well as behaviors - wagging, barking,
eating, etc. An object is an instance of a class.
CAR INVENTORY MANAGEMENT

Class - A class can be defined as a template/blueprint that describes


the behaviors/states that objects of its type support.

Methods - A method is basically a behavior. A class can contain many


methods. It is in methods where the logics are written, data is
manipulated and all the actions are executed.

Data types refer to an extensive system used for declaring variables


or functions of different types. The type of a variable determines
how much space it occupies in storage and how the bit pattern
stored is interpreted.

Data Types Available in VB.Net

VB.Net provides a wide range of data types. The following table


shows all the data types available:

Data Type Storage Allocation Value Range

Boolean Depends on implementing platform True or False

Byte 1 byte 0 through 255 (unsigned)


Char 2 bytes 0 through 65535 (unsigned)

Date 8 bytes 0:00:00 (midnight) on January 1, 0001 through


11:59:59 PM on December 31, 9999

CAR INVENTORY MANAGEMENT

INTRODUCTION TO MICROSOFT SQL SERVER


SQL is invented and developed by IBM in early 1970's.SQL stands for
Structured Query Language. IBM was able to demonstrate how to
control relational databases using SQL. The SQL implemented by
ORACLE CORPORATION is 100% compliant with the ANSI/ISO.

Standard SQL Data Language. Oracle’s database language is SQL,


which is used for strong storing and retrieving information on
oracle. A table is primary database object of SQL that is
used to store data. A table holds data in the form of rows
and columns.

Benefits of SQL:

• Non-procedural language, because more than one record can be


accessed rather than one record at a time.

• It is the common language for all relational databases. In other


words it is portable.

• And it requires very few modifications so that it can work on other


databases.
• Very simple commands for querying, inserting, deleting and
modifying data and objects.

CAR INVENTORY MANAGEMENT

Database Concepts

Database is the method to store data. If you have an application that


has to store and retrieve data, your application must be using a
database.

A file is the simplest form of saving the data in the disk, but is not
most efficient way of managing application data. A database is
basically a collection of one more files, but in a custom format, and
data is organized in a specific format such a way that it can be
retrieved and stored very efficiently.

Some examples for database are:

• MS access

• SQL Server

• Oracle

MS Access is a very light weight database provided by Microsoft for


application with less number of user and relatively small quantity of
data. MS access saves data into database files with the extension
.mdb. Usually, MS Access comes along with MS office package. If you
already have the .mdb database file, you can freely use it with your
application and do not need MS Access software.

CAR INVENTORY MANAGEMENT

The MS Access software is required only if you want to directly open


the database and manipulate the data or change the database
schema.

SOL server (Microsoft product) and oracle (Oracle Corp.) Are most
complex, advanced, relational database and they are much more
expensive. It can support large number of users and very high quality
of data. If you are developing a software, which may be accessed
simultaneously by 100s of users or if you expect your data may grow
100s of MBs, you may consider one of these. (We are provides
special data access components!!)

In this tutorial, we will be using only MS Access for simplicity. Most


of the samples provided in this site uses MS Access database for
simplicity and easy download.
CAR INVENTORY MANAGEMENT

SQL COMMAND METHODS

SqlCommand.BeginExecuteNonQuery Method: Initiates the


asynchronous execution of the Transact-SQLstatement or procedure
that is described by this SqlCommand.

This member is overloaded. For complete information about this


member, including syntax, usages, and examples, click a name in the
overload list.

SqlCommand.BeginExecuteReader Method: Initiates the asynch


-ronous execution of the transact SQL statement or stored procedure
that is described by this SqlCommand, and retrieves one or more
results sets from the server.

This member is overloaded. For complete information about this


member, including syntax, usages, and examples, clicka name in the
overload list.
SqlCommand.Clone Method: Creates a new SqlCommand object that
is a copy of the current instance.

CAR INVENTORY MANAGEMENT

SqlCommand. DisposeMethod:this member is overloaded.


For complete information about this member, including
syntax,usage,and. examples, click a name in the overload list.
SqlCommand.EndExecuteNonQuery Method:Finishes asynch
-ronous execution of transact-SQl statement.
SqlCommand.EndExecuteReader Method:Finishes
asynchrony -ous execution of transact-SQl
statement,returning the requested SqlDataReader.
SqlCommand.ExecuteNonQuery Method:Executes a transact-
SQL statement against the connection and returns the
number of rows affected.
SqlCommand.Executereader Method:This member is
overloaded. For complete information about this
member,including syntax, usages, and examples, click a name
in the overload list.
SqlCommand.ExecuteScalar Method: Executesthe query,and
returns the first columns of the first row in the result set
returned by the query, additional columns or rows are
ignored.
Data AdapterClass:Represents the set of data commands and
a database connection that are used tofill the data set and
update the data source.

CAR INVENTORY MANAGEMENT

Retrieving Data Using the DataReader:You can use the ado.net data
reader to retrieve a read-only, forward-only stream of data from a
database. Results are returned as the query executes, and are stored
in the network buffer on the client until you request them using the
read method of the data reader. Using the data reader can increase
application performance both by retrieving data as soon as it is
available, rather than waiting for the entire results of the query to
be returned, and (by default) storing only one row at a time in
memory reducing system overhead.

What is Dataset?
A Dataset is an in memory representation of data loaded from any
data source. Even though the most common data source is database,
we can use dataset to load data from other data sources including
XML files etc. in this article, we will talk about the role of data set in
manipulating data from database. In .NET, a dataset is a class
provided by the .NET Framework. The dataset class exposes several
properties and methods that can be used to retrieve, manipulate and
save data from various data sources.

CAR INVENTORY MANAGEMENT

NORMALIZATION
CAR INVENTORY MANAGEMENT

INTRODUCTION TO NORMALIZATION
Normalization is the process of efficiently organizing data in a
database. Normalization is the way by which a given set of
relations are transformed to a new set of relation with a
more solid structure. Normalization is needed to allow any
relation in the database to be represented, to allow a
language like SQL to use powerful retrieval operations
composed of atomic operations, to remove anomalies in
insertion, deletion and updating, and reduce the need for
restructuring the database as new data types are added . The
normalization process defines a set of hierarchical normal
forms (NFs). several normal forms have been proposed,
including 1NF, 2NF, 3NF, BCNF(Boyce-Codd Normal From),
4NF, 5NF and so on.
Normalization is a set of rules and techniques concerned with
* Identifying relationship among attributes.
* Combining attributes to form relations.
* Combining relations to form database.

CAR INVENTORY MANAGEMENT

Benefits of normalization
* Elimination of redundant data storage.
* Close modeling of real world entities, processes, and their
relationships.
* structuring of data so that the model is flexible.

NORMAL FORMS
The data in the database can be considered to be in one of
the number of 'normal forms'. Basically the normla form of
the data indicates how much redundancy is in that data. The
normal forms have a strict ordering:
1. First Normal Form (1NF)
2. Second Normal Form (2NF)
3. Third Normal Form (3NF)
4. BCNF (Boyce-Codd Normal Form)
5. Fourth Normal Form (4NF)
6. Fifth Normal Form (5NF)

CAR INVENTORY MANAGEMENT

First Normal Form (1NF)


First Normal Form (1NF or Minimla Form) is a normal form
used in database normalization. A relational datdabase table that has
1NF is one that meets a certain minimum set of criteria. These
criteria are basically concerned with ensuring that the table is a
faithful representation of a relation and it is free of repeating groups.

Second Normal Form (2NF)


A table is in Second Normal Form (2NF) if and only if it is in
1NF and every non-key attribute is fully functionally dependent on
the whole of the primary key (i.e there are no partial dependencies).

A relation R in 2NF and only if it is in 1NF and every non-key


column depends on a key not a subset of a key. All non-prime
attributes oR must be fully functionally dependent on a whole key (s)
of the relation, not a part of the key.
Third Normal Form (3NF)
3NF is the Third Normal Form used in relation database
normalization. According to the Cord's definition, the table is set to
be in 3NF if and only if, that table is in the Second Normal Form
(2NF), and every attribute in a table that do not belong to a
candidate key, should directly depend

on every candidate key of that table the tables that comply with a
3NF generally do not contain anomalies. That occur when inserting,
deleting or updating records in the table.

CAR INVENTORY MANAGEMENT

Boyce Codd Normal Form (BCNF)


Boyce Codd Normal Form (BCNF) is a normal form used in
database normalization. It is a slightly stronger version of the Third
Normal Form (3NF). BCNF developed in 1974 by Raymond F.Boyce
and Edgar F.Codd to address certain types of anomaly not dealt with
by 3NF as originally defined. Only in rare cases does a 3nf table not
need the requirements of BCNF.

Fourth Normal Form (4NF)


Fourth Normal Form is based on multi-valued dependencies,
which is violated when a relation has undesirable multi-valued
dependencies and hence can be used to identify and decompose
such relations. A relation scheme R is in 4NF with respect to a set of
dependencies F if, for every nontrivial multi-valued dependencies X-
>F,X is a super key for R.

Fifth Normal Form (5NF)


A relation R is in 5NF also called projection-join normal form
(PJ/NF) if and only if every join dependency in R is implied by the
candidate keys of R. Fifth normal form (5NF) is level of database
normalization designed to reduce redundancy in relational databases
according multi-valued facts by isolating semantically related
multiple relationships. A table is said to be in the 5NF if and only if
every join dependency in it is implied by the candidate keys

CAR INVENTORY MANAGEMENT


DATA
STRUCTURE

CAR INVENTORY MANAGEMENT

LOGIN TABLE
FIELDNAME DATATYPE CONSTRAINTS

uName nchar(10) Not null

pWord nchar(10) Not null

SUPPLIER ENTRY TABLE


FIELDNAME DATATYPE CONSTRAINTS

SuppCode nvarchar(50) Primary key

SuppName nvarchar(50) Not null

Add1 nvarchar(50) Not null

Add2 nvarchar(50) Not null

add3 nvarchar(50) Not null

PinCode nchar(10) Not null

MobileNo nvarchar(50) Not null

cName nvarchar(50) Not null

MODEL DETAILS TABLE


FIELDNAME DATATYPE CONSTRAINTS
ModelName Varchar(50) Not null

details Varchar(50) Not null

CAR INVENTORY MANAGEMENT

COMPANY DETAILS TABLE


FIELD NAME DATATYPE CONSTRAINTS
CompanyName Varchar(50) Not null

details Varchar(50) Not null

COLOR DETAILS TABLE


FIELD NAME DATATYPE CONSTRAINTS
ColorName Varchar(50) Not null

details Varchar(50) Not null

TRANSPORTER DETAILS TABLE


FIELD NAME DATATYPE CONSTRAINTS
TransporterCode nvarchar(50) Primary key

TransporterName nvarchar(50) Not null

add1 nvarchar(50) Not null

MobileNo nvarchar(50) Not null

cName nvarchar(50) Not null

CAR INVENTORY MANAGEMENT

CAR DETAILS TABLE


FIELD NAME DATATYPE CONSTRAINTS
BillNo float Primary key

slno int Not null

procode varchar(50) Not null

irate money Not null


iQty int Not null

taxAmt money Not null

totAmt money Not null

rem1 varchar(50) Not null

CAR INVENTORY MANAGEMENT


CODING

CAR INVENTORY MANAGEMENT

CODE FOR SAVE


Private Sub butSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles butSave.Click
SaveRecord()
butNew.Enabled = True
butSave.Enabled = False
butModify.Enabled = False
ButDelete.Enabled = False
butPrint.Enabled = True
End Sub
Sub SaveRecord()
Dim cmd3 As New SqlCommand
'If TextBox1.Text = "" Then
' MsgBox("Please enter the necessary details")
' Exit Sub
'End If
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
Dim Cmd0 As New SqlCommand("select max(Billno) from CarTranMainTab", Conn)
Dim D1 As SqlDataReader = Cmd0.ExecuteReader()
If D1.HasRows Then
D1.Read()
BillNoVar = Val(D1(0).ToString) + 1
If Conn.State = ConnectionState.Open Then Conn.Close()
End If
TextBox1.Text = BillNoVar
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
q1Var = "insert into CarTranMainTab("
q2Var = " values("
q1Var = q1Var & "billNo" & ","
q2Var = q2Var & "" & BillNoVar & ","
q1Var = q1Var & "BDate" & ","
q2Var = q2Var & "'" & bDate.Value & "',"
q1Var = q1Var & "PartyCode" & ","
q2Var = q2Var & "'" & ComboBox1.Text & "',"
q1Var = q1Var & "Transporter" & ","
q2Var = q2Var & "'" & TextBox1.Text & "',"
q1Var = q1Var & "Btype" & ","
q2Var = q2Var & "2,"
q1Var = q1Var & "tAmt" & ","
q2Var = q2Var & "" & Val(TxtT1.Text) & ","
q1Var = q1Var & "Add1" & ","
q2Var = q2Var & "" & Val(TxtT2.Text) & ","
q1Var = q1Var & "gtAmt" & ","
q2Var = q2Var & "" & Val(TxtT3.Text) & ","
q1Var = q1Var & "Rem1" & ")"
q2Var = q2Var & "'" & txtRem.Text & "')"

'MsgBox(q1Var & q2Var)


Dim cmd1 As New SqlCommand(q1Var & q2Var, Conn)
cmd1.ExecuteNonQuery()

CAR INVENTORY MANAGEMENT

For Each r As DataGridViewRow In DG2.Rows


If Conn.State = ConnectionState.Open Then Conn.Close()
If Not r.Cells(0).Value = "" Then
q1Var = "insert into CarTranDetTab("
q2Var = " values("
q1Var = q1Var & "billNo" & ","
q2Var = q2Var & "" & BillNoVar & ","
q1Var = q1Var & "slNo" & ","
q2Var = q2Var & "" & I & ","
q1Var = q1Var & "ProdCode" & ","
q2Var = q2Var & "'" & r.Cells(0).Value & "',"
q1Var = q1Var & "iRate" & ","
q2Var = q2Var & "" & Val(r.Cells(1).Value) & ","
q1Var = q1Var & "iQty" & ","
q2Var = q2Var & "" & Val(r.Cells(2).Value) & ","
q1Var = q1Var & "TaxAmt" & ","
q2Var = q2Var & "" & Val(r.Cells(3).Value) & ","
q1Var = q1Var & "totAmt" & ","
q2Var = q2Var & "" & Val(r.Cells(4).Value) & ","
q1Var = q1Var & "Rem1" & ")"
q2Var = q2Var & "'')"
Conn.Open()
cmd3.Connection = Conn
cmd3.CommandText = (q1Var & q2Var)
cmd3.ExecuteNonQuery()
End If
Next

disRecords()

End Sub
Sub disRecords()
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
Dim DS1 As New DataSet
Dim adp As New SqlDataAdapter("Select Billno,PartyCode From CarTranMainTab
order by Billno DESC", Conn)
adp.Fill(DS1)
DG1.DataSource = DS1.Tables(0)
If Conn.State = ConnectionState.Open Then Conn.Close()
End Sub

CODE FOR MODIFY


Private Sub butModify_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Handles butModify.Click
If vbNo = MsgBox("Are you sure you want modify this record",
MsgBoxStyle.YesNo, "Delete") Then Exit Sub
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
Dim cmd1 As New SqlCommand("Delete from CarTranMainTab where billNo=" & pkVar
& "", Conn)
cmd1.ExecuteNonQuery()

CAR INVENTORY MANAGEMENT

If Conn.State = ConnectionState.Open Then Conn.Close()


Conn.Open()
Dim cmd2 As New SqlCommand("Delete from CarTranDetTab where billNo=" & pkVar &
"", Conn)

cmd2.ExecuteNonQuery()
If Conn.State = ConnectionState.Open Then Conn.Close()
SaveRecord()
butNew.Enabled = True
butSave.Enabled = False
butModify.Enabled = False
ButDelete.Enabled = False

End Sub

CODE FOR DELETE


Private Sub ButDelete_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Handles ButDelete.Click
If vbNo = MsgBox("Are you sure you want delete this record",
MsgBoxStyle.YesNo, "Delete") Then Exit Sub
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
Dim cmd1 As New SqlCommand("Delete from CarTranMainTab where billNo=" & pkVar
& "", Conn)
cmd1.ExecuteNonQuery()
If Conn.State = ConnectionState.Open Then Conn.Close()
disRecords()
butNew.Enabled = True
butSave.Enabled = False
butModify.Enabled = False
ButDelete.Enabled = False

End Sub

CODE FOR NEW


Private Sub butNew_Click1(ByVal sender As Object, ByVal e As System.EventArgs) Handles
butNew.Click
DG2Init()
ClearTxtControls(Me, 1)
ComboBox2.Focus()
butNew.Enabled = False
butSave.Enabled = True
butModify.Enabled = False
ButDelete.Enabled = False
butPrint.Enabled = False
End Sub

CAR INVENTORY MANAGEMENT

CODE FOR CLOSE


Private Sub butClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles butClose.Click
Me.Close()
End Sub
CODE FOR LIST
Private Sub butList_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles butList.Click
disRecords()
End Sub

CODE FOR PRINT


Private Sub butPrint_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles butPrint.Click
PP1.ShowDialog()
End Sub

CODE FOR DISPLAY


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles Button1.Click
If Conn.State = ConnectionState.Open Then Conn.Close()
Conn.Open()
Dim DS1 As New DataSet
Dim adp As New SqlDataAdapter("Select billNo,bDate,PartyCode,tamt From
CarTranMainTab where btype=2 order by BillNo,bDate", Conn)
adp.Fill(DS1)
DG1.DataSource = DS1.Tables(0)
If Conn.State = ConnectionState.Open Then Conn.Close()
End Sub

CODE FOR LOGIN


Imports System.Data.SqlClient
Public Class LoginForm

Private Sub OK_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)


Handles OK.Click

CAR INVENTORY MANAGEMENT

If Conn.State = ConnectionState.Open Then Conn.Close()


Conn.Open()

Dim Cmd0 As New SqlCommand("select * from UserLoginTab where uName='" &


UCase(UsernameTextBox.Text) & "' and pword='" & PasswordTextBox.Text & "'", Conn)
Dim D1 As SqlDataReader = Cmd0.ExecuteReader()
If D1.HasRows Then
MDIForm1.Show()
Me.Hide()
If Conn.State = ConnectionState.Open Then Conn.Close()
Else
MsgBox("Username or Password is not correct please check")
End If

End Sub

Private Sub Cancel_Click(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles Cancel.Click
End
End Sub

Private Sub LoginForm_Load(ByVal sender As System.Object, ByVal e As


System.EventArgs) Handles MyBase.Load

End Sub
End Class

CAR INVENTORY MANAGEMENT


OUTPUT
SCREENS

CAR INVENTORY MANAGEMENT


CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
CAR INVENTORY MANAGEMENT
FUTURE ENHANCEMENT
 There is always a room for improvement in any software
package, however good and efficient it may be.
 But the improvement thing is that the system should be flexible
enough for further modifications.
 Considering the important factor, the system is designed in
such a way that provisions can be given for further
enhancement without affecting the presently developed.

CAR INVENTORY MANAGEMENT


CONCLUSION
 The system was mainly designed to reduce the manual work of
updating and tracking and also make it easier for the user.
 It also provides flexible and powerful reports regarding
customer details, supply details and stock details.
 Thus inventory system was implemented successfully.

You might also like