Monday, March 19, 2012

List SSRS2005 items on treeview

Hi all,

I'm creating a Custom web interface for SQL Server reporting services 2005.

What I want to do is populate a "Navigation Treeview" component in asp.net 2. How would I get all the catalog items and items from the web API and populate my treeview?

Thanks

Hi Rudi,

You could use the SOAP API - ListChildren. Here is a link to defintion and code sample:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/RSPROG/htm/rsp_ref_soapapi_service_lz_2yt2.asp

|||

Hi there Brad,

Thanks alot! I'm still having some trouble though...

I'm using this code to get the list:

Try

Dim P As New ReportingService

Dim RootList As CatalogItem = P.ListChildren("/", True)

LoadTree(RootList)

Catch ex As Exception

End Try

But this is returning the error:

\\Reportserver\NetReports\Admin\Default.aspx(1): Build (web): \\Reportserver\NetReports\MasterPage.master.vb(36): error BC30311: Value of type '1-dimensional array of ReportService.CatalogItem' cannot be converted to 'ReportService.CatalogItem'.

What am I doing wrong?

Thanks

|||

Don't worry, I got it....

I didn't add the () in

Dim RootList As CatalogItem() = rs.ListChildren("/", True)

Thanks

|||Any chance you could provide the code used for LoadTree? I'm stuck trying to figure out how to programmatically build the nodes from the CatalogItem.

Thanks,
Kel

No comments:

Post a Comment