473,385 Members | 1,712 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.

Searchable Generic

Bob Ross
119 100+
I have recently been looking into using generics to hold collections of objects as I like the type safe features they provide. But I want to be able to store objects with a key for easy finding. Which is the best object to do this? Is it a dictionary?
Aug 11 '08 #1
4 876
Plater
7,872 Expert 4TB
Dictionary<string, object>, is that what you are referring to?
Aug 11 '08 #2
Frinavale
9,735 Expert Mod 8TB
Have you looked into using LINQ?
Aug 12 '08 #3
Bob Ross
119 100+
I was referring to Generic.Dictionary(Of String, Object)

I have had a brief look at LINQ but I think to implement it would require an overhaul of the site somewhat. It doesn't seem to make sense to use it only in one place.
Also the objects I am building are not from database tables but from settings defined as committed text in the stored procedures. Which I don't think LINQ would be any good for.
Aug 12 '08 #4
Frinavale
9,735 Expert Mod 8TB
I was referring to Generic.Dictionary(Of String, Object)

I have had a brief look at LINQ but I think to implement it would require an overhaul of the site somewhat. It doesn't seem to make sense to use it only in one place.
Also the objects I am building are not from database tables but from settings defined as committed text in the stored procedures. Which I don't think LINQ would be any good for.
LINQ isn't just for database stuff, it lets you use SQL like commands on your objects too. The demonstrations I've seen are really cool...but I haven't tried it in any of my applications yet.

Anyway, have you looked at using a Hash Table?
Hash tables let you store objects with a key....
Aug 12 '08 #5

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

Similar topics

6
by: Alexandre Plennevaux | last post by:
hello mates, my question is such: should i turn a 80 pages doc file into a database so that: - i can make it searchable through an online form - it can be modified and every modification...
3
by: Job Lot | last post by:
I am trying to implement searchable DataGrid. I am creating a DataSet object with DataRelation on form load, as follows: Private Sub BindDataGrid() Dim planTS As New DataGridTableStyle Dim appTS...
5
by: PR | last post by:
Searchable product images + prices database? What system should I use to put a database on the WEB which shows images and allows searches, including searches within given price ranges for...
4
by: Vadim | last post by:
How To Make Searchable Combobox in ASP.NET? For example: When start typing R it has to show first item starting with 'R' if continue Ro it has to show items starting with 'Ro' How to...
9
by: mps | last post by:
I want to define a class that has a generic parameter that is itself a generic class. For example, if I have a generic IQueue<Tinterface, and class A wants to make use of a generic class that...
3
by: Bhadan | last post by:
This is a beginner question: I wish to make a textbox searchable for strings. Is this possible with a property of the textbox, or do I have to wright a method. TIA. Bhads.
13
by: rkausch | last post by:
Hello everyone, I'm writing because I'm frustrated with the implementation of C#'s generics, and need a workaround. I come from a Java background, and am currently writing a portion of an...
7
by: Dave | last post by:
I've got these declarations: public delegate void FormDisplayResultsDelegate<Type>(Type displayResultsValue); public FormDisplayResultsDelegate<stringdisplayMsgDelegate; instantiation:...
5
by: just another hacker | last post by:
Word Up Friends ~ I wuz after an online copy of K&R C book... found me a pdf, but it's only got scanned text. Can ppl suggest a url with fully searchable text of the book? Thanx M8S.
18
by: Pieter | last post by:
Hi, I need some type of array/list/... In which I can store objects together with a unique key. The most important thing is performance: I will need to do the whole time searches in the list of...
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:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...

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.