Solved

Sharepoint List Querry

Posted on 2013-01-20
3
233 Views
Last Modified: 2013-01-25
I need to show the qurry result of a list in sharepoint in datagrid view that I have in a web part. How can I do this? How can I run a querrry based on the list data and bind it in gridview? Is there a sample code that someone might have??
0
Comment
Question by:pauledwardian
3 Comments
 
LVL 1

Expert Comment

by:bounty457
ID: 38798195
0
 
LVL 14

Accepted Solution

by:
KoenVosters earned 500 total points
ID: 38800363
You can use CAML Designer to build the query:

http://sharepoint.biwug.be/SitePages/Caml_Designer.aspx

You can use SPQuery Class to run the query (see example)

http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spquery.aspx

You can get the DataTable propertie on the returned listitems to bind to your grid.
0
 

Author Closing Comment

by:pauledwardian
ID: 38820352
thanks!
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

There is one common problem that all we SharePoint developers share: custom solution deployment. This topic can't be covered fully in this short article, so all I want to do in this one is to review it from a development-to-operations perspectiv…
SharePoint Designer 2010 has tools and commands to do everything that can be done with web parts in the browser, and then some – except uploading a web part straight into a page that is edited in SPD. So, can it be done? Scenario For a recent pr…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now