.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Type in first few characters to select items in a large list quicker

Posted By:      Posted Date: October 11, 2010    Points: 0   Category :Sql Server
is there a way that you can type in the first few characters of an item in a dropdown box eg if you type ‘rad’ in the dropdown box it will take you to the first item starting with ‘rad’.

Is it possible that you could type in rad to get you to radiator for example?

View Complete Post

More Related Resource Links

ORDER BY items must appear in the select list if SELECT DISTINCT is specified


Hi, i am using a query to get DISTINCT hotels from my Database table sorted by Price and it returns me same hotel times of record found by Price if i use this Query

SELECT distinct(hotelname), availstatus, hoteladdress, hotelphonenumber, hotelpostalcode, destination, starrating, imageurl, hotelcode, TempSession, HotelType, MinimumNightRate from HproTemp where TempSession = '12-53-37' ORDER BY MinimumNightRate

and i get the error "ORDER BY items must appear in the select list if SELECT DISTINCT is specified" When i remove MinimumNightRate from SELECT LIST.

Can anyone have any idea how may i resolve it..

ORDER BY items must appear in the select list if SELECT DISTINCT is specified


why am i getting the error message when both ORDER BY items appear in the SELECT query?



	CONVERT(VARCHAR(8),BI.DateFrom ,3) as FFromDate,
	CONVERT(VARCHAR(8),B.CreatedDate ,3) as FBookingDate,
	CAST(FLOOR( CAST( B.CreatedDate AS FLOAT ) ) AS DATETIME) as BookingDate,
	(C.Forename + CASE 

Change the content type for multiple list items


I have a document library which is configured to manage content types.  Users will be expected to upload multiple documents into the library.  Then they will be expected to choose the content type of the file and fill in the required metadata.  The only difference in these content types is the template which will be used to create new files of the specific content type so the columns are identical for each content type.

I have created a public view with inline editing enabled but Content Type is not an editable field.

The problem I have is that when I enable Inline editing, the users don't have an opportunity to select the content type, even though the files have just been uploaded and have not been checked in.

My question is this; how can users change the content type of multiple items without having to go through the complete New Item form? 

With literally thousaands of documents to be imported, having the users fill out a separate form for each document when many will have the same column values is a show stopper for our rollout.  It will take too much time.  The project will be a failure. 

I've also tried to create a datagrid view but the same problem exists.  Content type is not an editable column value.

Thanks for helping.


SPquery skips or omits some items in large list


I am using below SPQuery  with known options for better performance like rowlimit and pagenation and including sub-folders.

SPWeb objWeb = mySite.OpenWeb();

SPList objList = objWeb.Lists["My list"];

SPQuery myQuery = new SPQuery();

myQuery.Query = "<Where><Eq><FieldRef Name='Title'/><Value Type='Text'>"+myValue+"</Value></Eq></Where>";

SPListItemCollection myItemcoll = objList.GetItems(myQuery);

myQuery.RowLimit = 2000;

myQuery.ViewAttributes = "Scope='RecursiveAll'";



   foreach (SPListItem item in myItemcoll)



    Console.WriteLine("Item title:{0}", item["Title"]);

     Console.WriteLine(" Clinent : {0}", item["Client"]);


   myQuery.ListItemCollectionPosition = stateCol.ListItemCo

MOSS 2007 This list or library contains a large number of items.


I have a library showing "This list or library contains a large number of items.".

The library contains only 1300 items.


1. Would the performance, e.g., upload files/change item properties, be affected?

2. Any way I can better organize the items?

3. I kown we can create folders in a library, how can I create subfolder? Or subfolder refers to Content Type?

4. Would create content type improves performance?


Many thanks.

Creating Sites/Lists/List Items under Current User Context in SharePoint By Using SPUserToken

Usually we do this by performing the action under RunWithElevatedPrivileges method and updating the listitem using SPListItem.SystemUpdate() method (see here). but this approach has its own flaws like (RunWithElevatedPrivileges will run under system account, we cannot use SystemUpdate for SPSite,SPWeb,SPList, since it runs under system we will "CreatedBy" by as SystemAccount).

Get pixel format, raw format, property id list and property items image in VB.net - C#.net.

n this simple article you will learn that how we can get pixel format, raw format, property id list and property items image in VB and C#.net.

Get Pixel Format:

Image consists of pixels to get the format of the pixel we have a property named pixel format. This property returns an enumeration of pixel format. This enumeration tells the pixel format.

To demonstrate make a window application. Drag one button and a picture box on form.

Now write the following code on Button click event:

Way of adding items in Drop Down List or List Box using Javascript

The article Way of adding items in Drop Down List or List Box using Javascript was added by raja.s on Sunday, June 06, 2010.

Hi,script type="text/javascript"> function AddItem(Text,Value) { // Create an Option object var opt = document.createElement("option"); // Add an Option object to Drop Down/List Box document.getElementById("DropDownList"

How to Customize the Add Comment 'Items on this list require content approval...' notification in


WSS 3.0:

If content approval is turned on, the Add Comment section displays a fairly ugly notification. Is there any way I can customize that section through e.g. CSS or SPDesigner?

I'd like to change at least the text, and preferably the yellow exclamation image, and also the background if possible.

Add Items to List with BDC Column via Web Services

I really hope this is possible.  I am trying to add items to a list that have a BDC column as one of the fields.  Here is the code I am using in the Batch

batchElement.InnerXml = "<Method ID='1' Cmd='New'>" +  
"<Field Name='Title'>Hello World</Field>" +  
"<Field Name='bdc'>BDCIdentifier</Field>&

Use BDC data in list as multi-select column

I have a document library that uses values from another system for its metadata.  Right now, we copy the values from the primary system into SharePoint so users can choose them.  I want to find a way to use the BDC connection that I have set up to automatically pull those values.  The problem is that the current metadata is set to multi-select.  So, I have a file that is in the library and it can be used for multiple clients - clients is a column in my library and users can select many entries.  When I set up a column to pull BDC data, it only allows single entry.  Does anyone have any ideas?

Display tooltip for Sharepoint list items


Hi All,

I am using MOSS 2007 and my requirement is to show tooltip when I hover the mouse over the title column for each item. I am planning on storing the tooltip string for each listitem in a seperate column. Is there a way to do it. I am sure there is. Any help is greatly appreciated.

Thanks in advance!




Issue with List Definition of same base content type and deployed via same feature


I am trying to deploy two custom list definitions using only one single feature.  Below are the details of my issue.

  • Two custom list definitions
  • Each custom list definition has its own custom content type
  • Each custom content type inherits from the base content type Picture (Type = 109)
  • The custom list definitions are grouped together under one single feature
  • The custom content types are grouped together under a seperate single feature

When I deploy my solution in this configuration, the second list definition gets the first custom content type applied to it and the list schema from the first list definition is also applied to the second list definition.

What makes this more interesting, when I seperate both of the list definitions under two seperate features it all works fine.  Custom content types and list schemas get applied correctly.

Can anyone tell me why I can not deploy both list definitions under one single feature?

If you need me to post any of the origional code or XML to this post please let me know.



Delete list items en masse?

Is there a way to delete list items en masse from a SP list?  I am on MOSS 2007.  In order to use a particular site as a site template I had to save with content and I don't want the content.

Video: Large List Support in SharePoint 2010

SharePoint 2010 has support for very large lists of up to 50 million items. With this expanded list size comes the ability to throttle and control how much data is returned to the user and prevent large queries from compromising the SharePoint farm. (Length: 15:36)

Variable/Argument Type List

Hi I wish to restrict or supply my own list of (Variable/Argument) types to a rehosted Workflow Designer. Is this definatley not possible? I have read http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/53c91c81-02cf-4eab-b43f-c3d73a03c501, where it appears it is not. I find it difficult to believe I cannot get some sort of control of how these drop downs are populated. Could someone please confirm categorically that this is or is not possible. Regards DarremDarren
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend