473,699 Members | 2,226 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Need help - trying to create a searchable list

I am currently working on an application for our Business Office to
easily search for new budget codes that we have to establish due to an
administrative system conversion we are currently undergoing. They
would like to be able to find a new code via searching by old code or
searching by the object name. I have the search by old code form done
exactly the way they want it. For the search by object name form, I
have it set up with a combo box and a subform with three fields (old
code, name, new code). I set it up so you can select a name from the
combo box and it would automatically display only the records with that
name in the subform. However, the names I am working with are rather
long, and the department I'm creating this application for would like
to be able to type in a portion of the name and be able to see all
records that contain the text that they enter (regardless of where the
text is located in the field). I've tried using the command button
wizard, but it's no help. I've tried creating macros, but was
unsuccessful there as well. Can someone out there offer me any
suggestions? Thanks in advance.

Derek Jones
Software Support Specialist
Shenandoah University
Winchester, VA

Nov 13 '05 #1
2 2033
If you use a combobox, you can change the rowsource on the fly. and
then in column(1), which is second column, you can show whatever you
like and if your LimitToList option is set to true and AutoExpand is
true, the user can just start typing the value he wants and the
Combobox will scroll to that section of the list.

you could set the rowsource on the fly and then requery it.

Nov 13 '05 #2
Derek Jones wrote:
I am currently working on an application for our Business Office to
easily search for new budget codes that we have to establish due to an
administrative system conversion we are currently undergoing. They
would like to be able to find a new code via searching by old code or
searching by the object name. I have the search by old code form done
exactly the way they want it. For the search by object name form, I
have it set up with a combo box and a subform with three fields (old
code, name, new code). I set it up so you can select a name from the
combo box and it would automatically display only the records with that
name in the subform. However, the names I am working with are rather
long, and the department I'm creating this application for would like
to be able to type in a portion of the name and be able to see all
records that contain the text that they enter (regardless of where the
text is located in the field). I've tried using the command button
wizard, but it's no help. I've tried creating macros, but was
unsuccessful there as well. Can someone out there offer me any
suggestions? Thanks in advance.

Derek Jones
Software Support Specialist
Shenandoah University
Winchester, VA


You'll probably want to use the LIKE operator in SQL to get the object
names containing the substring typed in by the user. Since you are
using a substring rather than the full string, you aren't going to be
able to use the form/subform's built-in field linking. It looks like
you're going to have to change the subform's RecordSource dynamically.
Maybe put a command button next to the textbox containing the
substring, that creates the SQL string and changes the RecordSource of
the subform. The code behind the command button's Click Event would
look something like (air code):

SubformObjectNa mes.Form.Record Source = "SELECT OldCode, ObjectName, _
NewCode FROM tblEquivalents WHERE [ObjectName] LIKE _
'*" & txtSubstring.Va lue & "*'"
SubformObjectNa mes.Form.Refres h
SubformObjectNa mes.Form.Repain t

Name is a reserved word so it's not a good idea to name a field 'Name.'

James A. Fortune

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2383
by: new_GUY | last post by:
I have a HUGE project (at least for me) and need some guidance. I am trying to create a database for a local university movie club that allows users to input there basic personal information (name, address, telephone number) as well as movies in there collection. The movies will be categorized by genre (comedy, romance, horror, etc.) and title. I want to be able to let the users add and remove movies to their list of movies they own,...
0
407
by: Apollo | last post by:
I have about 20K records that result from the following query. Front end for the database is ACCESS97 and pulling up 20K records makes a huge performance hit. For the form in question I am using PASSTHROUGH type query (the one that just passes everything straight to server without ODBC). NOTE: souce_for_inquiries_form is the TEMP table and is searchable in the from (it feeds a pull-down list). SELECT inquiries.inquiry_id,...
0
493
by: Apollo | last post by:
1.2Ghz Pentium, with 1/2Gig of ram, 4.0.14MySQL, RedHat9.0 I have about 20K records that result from the following query. Front end for the database is ACCESS97 and pulling up 20K records makes a huge performance hit. For the form in question I am using PASSTHROUGH type query (the one that just passes everything straight to server without ODBC). NOTE: souce_for_inquiries_form is the join table and is searchable in the from (it feeds a...
3
1445
by: Erik Thorsen | last post by:
Hello! I am in the process of creating a database listing tours, something similar to what you can find on www.infohub.com. This means that I need to create a database which can be searchable with destination, category, price and so forth. Unfortunately I can not seem to be able to create the relationships, neither can I make my head learn how to do this. I would be extremely happy if anyone could help me solve this problem for me or...
3
4318
by: sandrina | last post by:
Hello everyone, My name is Debi and I am an Administrative assistant with a large company in their sourcing department. I was hired one month ago, and walked in to a HUGE filing nightmare. My boss requires a paper copy of everything to be saved and filed. The vendors we purchase from produce hundreds of different products, with enough paper to sometimes fill half a filing cabinet on their own. Anyway, after discussing everything and...
5
3785
by: Learner | last post by:
Hello, Here is the code snippet I got strucked at. I am unable to convert the below line of code to its equavalent vb.net code. could some one please help me with this? static public List<RoleData> GetRoles() { return GetRoles(null, false); }
9
5249
by: Brian Hampson | last post by:
I am trying to determine all the groups which the current user has permissions to add a member. Here's my code: foreach (System.DirectoryServices.SearchResult ADSearchres in ADSearch.FindAll()) { //ActiveDs.ADSearchres.Properties
2
1218
by: NikiJ | last post by:
I just started as a webmaster for a Non-Profit and they have a ton of news articles, I would like to put them into a database and have them searchable on the website. I have the faintest idea how to do this. Also I need a way to put the articles in easily too. Niki
15
1968
by: rhino | last post by:
I've put together a prototype of two-tiered CSS tabs that works really well in IE6, IE7, and FF2. It also works very well in Opera 9.27 _except_ that the placement of the lower tier of tabs is messed up. Both the XHTML and CSS validate without any errors or warnings. Can anyone help me figure out what is wrong? I'd be especially interested in the technique you used to figure out where the problem was. I still struggle a lot when I try to...
0
8618
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9035
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8916
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8885
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6534
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5875
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4376
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4631
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3058
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.