Hi guys it will be very interesting for you to
know that we you can create a wonderful product of sale application in WPF using
Expression Blend. Till now you would have come across this application in .NET and java but in this article you will learn how to make this application in
Expression Blend. The main purpose of this application is not only to show you
how WPF can be used to create complex application but also to let you know how
to overcome all the intricate complexities that arise while designing an
application in blend. This is for sure that after knowing how to create this
project you will know all the basics required to create an application in Blend
and thereby you can create your own application.
There are few main parts of the application
that you need to go through before creating the application. First of all You
need to visualize all the things and functionality you would need your
application to incorporate within. This is the road map of how the application
would work ahead.
There will be a home page/window which is
the entry level of the application. In this we have
- A combobox, named "username" which has two entry type one is for admin and
the other for user. Here every time the user login he have to fill the small registration form so that he could get a instant
generated password to login for the sale and purchase of
products.
- Label, named "password" this is initially at the hidden state and becomes
visible only when the user is redirected from the register window to the login window and displays the password of the user.
- A text box, named "txtpass" which holds the password and allows the person
to login.
- A button, named "login" this is an event button which transfers the user to
the next window on successful login, otherwise it displays an error message on Label "password"
Then comes the Register page/window. In this window there is a small information form for the user to fill in and on the successful completion of the form the page redirects the user to the login window and displays the password above for the user to login now.
The Register window looks like the below figure:
This window consists of following label and
text fields :
- Name
- E mail id
- Occupation
- Nationality
- Phone no.
- Suggest password
- A register button , named register
Then there is the main window named as the "Admin" window. This window is where all the operation are laid and handled. This window looks like the below figure:
This window has the following components:
- A item box named as "Products" which
contains the list of all the products available to the user to sell of buy :
- One label as Quantity label named as "qty"
which displays the quantity of the product available.
- One label as the Price label named as
"price" which displays the price of the products available.
- A Modify button , named as "Modify" this
button gives the privileges to the user to edit the product details such as
quantity, product name, price and even delete the product. On the click of
this button the window asks for the administrator password and on providing
the correct password the editing buttons becomes visible now the user can
edit the product information.
- Buttons , there are five buttons used in
this context. One is the Add product button, named "btnnp" this button is
used to add the product to the List box with the name provided in the
textbox. Then the Add quantity button named as "btnqty" this button adds the
quantity of the product newly added to the list box. Then there is another
button named "btncp" to add the price of the product added recently. Also
there is a button to delete any product from the list box.
- Radio button , there are two radio buttons
in the window named as "buy" and "sell" respectively for the BUY and SELL
radio buttons. On selecting any one of the radio button the respective
activity is fired and if the product is "buy" selected then the quantity of
the product is changed and if the "sell" radio button is selected then the
quantity of the product is increased. This completes the sell and buy of the
product.
This is a mere introduction to the application; the next article will show up how to incorporate all of the functionality and all
the design and effect parts of the application. Do wait for the next part of this
article to reach you soon. You can put up your query or concerns regarding this
application by posting comments.