Visual Basic Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgrammingVisual Basic Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
Free Web 2.0 Code Generator! Generate data entry and reporting .NET Web apps in minutes. Quickly create visually stunning, feature-rich apps that are easy to customize and ready to deploy. Download Now!
  #1  
Old November 8th, 2004, 12:43 AM
shanny shanny is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 35 shanny User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 50 sec
Reputation Power: 5
Question Login Program using vb6

Hi all,

i am creating a login sreen using vb6+ms access2000. when user want to login to the system, he will key in usename n password, system thn check with access database whether the username n password are correct, if yes thn allow login. So, what's the method to do it?

pls advise ...thanks for ur help!!


Regards
Shanny

Reply With Quote
  #2  
Old November 10th, 2004, 06:06 AM
shaz shaz is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Nov 2004
Posts: 4 shaz User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by shanny
Hi all,

i am creating a login sreen using vb6+ms access2000. when user want to login to the system, he will key in usename n password, system thn check with access database whether the username n password are correct, if yes thn allow login. So, what's the method to do it?

pls advise ...thanks for ur help!!


Regards
Shanny

There are so many ways to do it. It depends for whom you are trying to build the application for. If it is for a professional company then you will need secure classes for in between data exchange security. If it is for minor organisation then still security is very important. But if you are trying to just learn on your own (which I think you are), then just write simple functions to 1) open the database connection 2) read the username one at a time to see if the match is found, if yes then check that if the corresponding password matches, if yes then provide access, other give invalid password error or user not found error. 4)dont forget the close the connection when you dont need to use the database. This also depends what kind of application you are developing. For small application at home use or testing, I would normally open the connection when the program starts and close the connnection when the program ends. But then there is a risk. If the program crashes in the middle, then the connection may still be open, and when you try to connect the next time, you may be denied access. In this case you may need to reboot the computer/server to clean the ram.

I hope this enough for you to get started.
Shaz

Reply With Quote
  #3  
Old November 10th, 2004, 10:21 AM
shanny shanny is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 35 shanny User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 50 sec
Reputation Power: 5
Wink

that means i have to write some coding that can check whether the username are vary with the password, rite? can u show me a sample on how the code look like?

i have link the form with the database, but aside to the coding... i have no idea on it! can u pls show me the code?? thanks in advanced!

Regards
shanny

Reply With Quote
  #4  
Old November 10th, 2004, 07:21 PM
shaz shaz is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Nov 2004
Posts: 4 shaz User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by shanny
that means i have to write some coding that can check whether the username are vary with the password, rite? can u show me a sample on how the code look like?

i have link the form with the database, but aside to the coding... i have no idea on it! can u pls show me the code?? thanks in advanced!

Regards
shanny


Of course you have to write some coding, and thats what visual basic is. It is for programmers, it is a programming language. Why you wanna do the above anyway? If you new to VB, this is not a good place to start learning it. Learn the VB basic's first. By me giving you any code will not help you. I am at work and my text books are at home, so I cannot remember the exact codes. If you start and have errors, I may be able to help you, but not everything from scratch...

Most ADO textbooks will be help ful to you.Try and grab one and you will see the solution. Hope this helps.
Shaz.

Reply With Quote
  #5  
Old November 11th, 2004, 10:35 AM
shanny shanny is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 35 shanny User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 50 sec
Reputation Power: 5
Quote:
Originally Posted by shaz
Of course you have to write some coding, and thats what visual basic is. It is for programmers, it is a programming language. Why you wanna do the above anyway? If you new to VB, this is not a good place to start learning it. Learn the VB basic's first. By me giving you any code will not help you. I am at work and my text books are at home, so I cannot remember the exact codes. If you start and have errors, I may be able to help you, but not everything from scratch...

Most ADO textbooks will be help ful to you.Try and grab one and you will see the solution. Hope this helps.
Shaz.



erm ok thanks for ur advised. i do in that way cause that is one part of my assignment given. so i have to try todone it. Anywhere, i will trying to do it, if i cant solve it, i will post my code here, n hope u will gv further advise, thanks in advanced.

Reply With Quote
  #6  
Old November 15th, 2004, 01:40 PM
x_c4_4u x_c4_4u is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Sep 2004
Location: Zimbabwe
Posts: 34 x_c4_4u User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 10 m 15 sec
Reputation Power: 4
Send a message via Yahoo to x_c4_4u
sample code

you said you are a beginner? well this code will be just for you. your tutor wont be angry with you for this.

i used textboxes which will be visible.false. The code extracts records from a database based on the username. it then checks to see if the password typed in a textbox2 matches that in a textbox which gets data from the database.

NB-->Just an example you wont get an 'A' with this code.
Attached Files
File Type: txt shanny.txt (964 Bytes, 892 views)

Reply With Quote
Reply

Viewing: ASP Free ForumsProgrammingVisual Basic Programming > Login Program using vb6


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway