473,385 Members | 1,185 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how do i display the company name starting with letter a in textbox

i am using dotnet 2003.i am doing my project in vb.net windows application.i have two form in my project.first form is datagrid .In second form label and textboxes are avilable to save the entering values in datagrid of first form through this 2nd form.my problem is,in 2nd form,if i enter letter a in findtextbox and i click find button means,i want to display the values automatically (assyst in companynametextbox,vijay in contactpersontextbox,cbe in addresstextbox)in 2nd form.
for example,
in first form,
there are 4 columns named as companyname,contactperson,address in datagrid.
values are assyst for companynamecolumn,vijay for contactperson column,cbe for address column.now values in datagrid like below
companyname contactperson address
assyst vijay cbe

in 2nd form,there are 4 label and 4 textbox.textbox are named as findtextbox,companynametextbox,contactpersontextbo x,addresstextbox.
my problem is,
in second form,
if i enter letter a in findtextbox and i click find button means,i want to display the values automatically (assyst in companynametextbox,vijay in contactpersontextbox,cbe in addresstextbox)in 2nd form.
during runtime in vb.net windows application.so how i do these.plz help me.
Jun 13 '07 #1
2 1728
Use the OnChange event of your textbox to select the records starting with that letter(s).
You will have to use the "LIKE" clause in your SQL SELECT statement to get the values starting with a specific value:

SELECT * FROM TableName WHERE CompanyName LIKE 'A%'

NOTE: The wild card character('%' in my example) is different depending on the Database engine used. You'll have to do some research to find the value for your provider if it doesn't work with '%'.
Jun 13 '07 #2
vanc
211 Expert 100+
i am using dotnet 2003.i am doing my project in vb.net windows application.i have two form in my project.first form is datagrid .In second form label and textboxes are avilable to save the entering values in datagrid of first form through this 2nd form.my problem is,in 2nd form,if i enter letter a in findtextbox and i click find button means,i want to display the values automatically (assyst in companynametextbox,vijay in contactpersontextbox,cbe in addresstextbox)in 2nd form.
for example,
in first form,
there are 4 columns named as companyname,contactperson,address in datagrid.
values are assyst for companynamecolumn,vijay for contactperson column,cbe for address column.now values in datagrid like below
companyname contactperson address
assyst vijay cbe

in 2nd form,there are 4 label and 4 textbox.textbox are named as findtextbox,companynametextbox,contactpersontextbo x,addresstextbox.
my problem is,
in second form,
if i enter letter a in findtextbox and i click find button means,i want to display the values automatically (assyst in companynametextbox,vijay in contactpersontextbox,cbe in addresstextbox)in 2nd form.
during runtime in vb.net windows application.so how i do these.plz help me.
In order to pass values between forms, you should look up delegate or attribute option. If you have a database running underneath, you should look up that database, this is much easier way to do this.
Try those ways, if it's still, give me a buzz.

Cheers.
Jun 13 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Michelle | last post by:
Hi, I want to display some pretty basic xml data in a .NET user control that I would like to build for my site. I am getting the XML from a URL that has been provided to me (i.e....
0
by: rakesh_cool12 | last post by:
Myself doing one form based application. where there will be one textbox. when i enter 1st letter in that textbox it will display all the website start with that letter in that form . i am doing...
3
by: remya1000 | last post by:
i'm using ASP with MSAccess as database. i have two buttons and two textbox in my page. when i press my first button (First month) i need to display the current month in one textbox and last one...
1
by: sathyan8294 | last post by:
i want to display the name starting with any letter(A-Z,a-z) in textbox from sqldatabase through datagrid using vb.net windows application. for example, values are in datagrid like companyid ...
2
by: backups2007 | last post by:
I have a customer information form that has a list box containing all the names of the customers. And when submitted and inserted to the database, automatically displays the information onto the list...
7
by: TechnoAtif | last post by:
Hi..There is again a similar problem..Now i;ve got the option values of list?menu box to show the textbox. If the option value of list is yes then the textbox is to be displayed . Can anyone...
0
by: =?Utf-8?B?RnJlZGVyaWMgSHV0b3c=?= | last post by:
I am trying to build a web site using C# 2005 and msSQL, and I am trying to build a page that displays for products : A B C D E F G ... Z # If there is something an item starting with the...
16
by: John | last post by:
I am looking for VBA code that will work with Access 2003 to enable dragging and dropping a file/folder name from Windows XP Explorer into an Access form's text box. This is a common functionality...
13
by: PhpCool | last post by:
Hi, since sometime I'm stuck in a problem where I want to check or uncheck all the checkboxes. If I'm choosing name for the checkbox array as 'chkbx_ary' then I'm able to check/uncheck all the...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.