Showing posts with label created. Show all posts
Showing posts with label created. Show all posts

Thursday, March 29, 2012

Cristal Reports for OLAP CUBE

I have created a crystal report connecting an OLAP cube .But once i
try to view a report it took around 15 minutes and finaly gave an
error like "cannot retrieve data from cube".I want to know why it is
and how can i create a crystal report for OLAP CUB."Pradeep" <aprpradeep@.hotmail.com> wrote in message
news:3f64305f.0402250014.39e80bee@.posting.google.c om...
> I have created a crystal report connecting an OLAP cube .But once i
> try to view a report it took around 15 minutes and finaly gave an
> error like "cannot retrieve data from cube".I want to know why it is
> and how can i create a crystal report for OLAP CUB.

It sounds more like a Crystal Reports question than an MSSQL one, but you
may want to try posting in microsoft.public.sqlserver.olap, to see if anyone
there has experience of this.

Simon|||"Pradeep" <aprpradeep@.hotmail.com> wrote in message
news:3f64305f.0402250014.39e80bee@.posting.google.c om...
> I have created a crystal report connecting an OLAP cube .But once i
> try to view a report it took around 15 minutes and finaly gave an
> error like "cannot retrieve data from cube".I want to know why it is
> and how can i create a crystal report for OLAP CUB.

You may want to capture a trace using the Profiler tool which should show
you what SELECT statements are being passed from Crystal. See BOL on
Profiler. Once you capture the trace you could then run the SELECT
statement(s) in Query Analyzer which may tell you if you are having an issue
with your reporting tool or if your SELECT statements cause errors or
timeouts.|||"Terri" <Terri@.spamaway.com> wrote in message news:<c1jmk1$33q$1@.reader2.nmix.net>...
> "Pradeep" <aprpradeep@.hotmail.com> wrote in message
> news:3f64305f.0402250014.39e80bee@.posting.google.c om...
> > I have created a crystal report connecting an OLAP cube .But once i
> > try to view a report it took around 15 minutes and finaly gave an
> > error like "cannot retrieve data from cube".I want to know why it is
> > and how can i create a crystal report for OLAP CUB.
> You may want to capture a trace using the Profiler tool which should show
> you what SELECT statements are being passed from Crystal. See BOL on
> Profiler. Once you capture the trace you could then run the SELECT
> statement(s) in Query Analyzer which may tell you if you are having an issue
> with your reporting tool or if your SELECT statements cause errors or
> timeouts.

Profiler probably won't help here - as far as I know, it works with
connections to SQL Server only, not to Analysis Services.

Simon

Cretae a view in one DB with a stored procedure from another DB

Hi,

Ik created an application with visuals basic.NET. This has a
connection string to one database, let's say 'A'. In this database a
stored procedure is called which should execute a string (which is
passed by the) VB tool. This string is a CREATE VIEW statement en this
should be executed in another database let's say 'B'.

I tried this in Transact - SQL

EXEC('USE B;' + Query)

An error occurs : CREATE VIEW should be the first in a batched
statement.

Could anyone help me with this one?

Greetz,
Hennie"Hennie de Nooijer" <hdenooijer@.hotmail.com> wrote in message
news:191115aa.0405240403.724292f@.posting.google.co m...
> Hi,
> Ik created an application with visuals basic.NET. This has a
> connection string to one database, let's say 'A'. In this database a
> stored procedure is called which should execute a string (which is
> passed by the) VB tool. This string is a CREATE VIEW statement en this
> should be executed in another database let's say 'B'.
> I tried this in Transact - SQL
> EXEC('USE B;' + Query)
> An error occurs : CREATE VIEW should be the first in a batched
> statement.
> Could anyone help me with this one?
> Greetz,
> Hennie

You need a GO right before the CREATE VIEW statement, and this won't work in
dynamic SQL. In any case, this isn't really a good way to create a database
object - it would probably be a lot easier for your client application to
connect directly to database B. Or if you really want to do it from SQL,
then why not create the stored procedure in database B and call it from
database A?

It might help if you can explain what you're trying to achieve, and someone
may be able to suggest a better solution, as creating objects dynamically
from a user application can create significant problems with security and
maintenance. But since you didn't say what your goal is, you may have a good
reason for doing this.

Simon

Credentials used to run this report are not stored.

I created a report in SSRS, and deployed it. I have created security where when users run the on demand report, it will prompt them for a username and password. I went to the properties of the report then Execution, and tried to set up report execution snapshot and got an error 'Credentials used to run this report are not stored.' I get the same error if I go to History and try to select any of the options there.

Hello,

In order to create a subscription/snapshot, you have to store credentials to run the report. If you don't store the credentials, when it goes to run unattended, it has no connection information.

Jarret

|||Where do I store these credentials?|||

Hello,

Go to the properties of your report, then click on 'Data Sources' on the left. In here, select 'Credentials stored securely in the report server' and supply a username and password. If you use a Windows account, you have to give the domain as well (domain\user) and check the box for 'Use as Windows credentials when connecting to the data source'. Hit Apply.

Hope this helps.

Jarret

|||That worked....thanks!!

Credentials trouble, please help

Hello,
When I created the datasource for my report, I checkd the save checkbox to
save the username and password to connect to the database, but invoking the
report thru URL integration fails and gives an error b/c of credentials. Why
is that happening if the credentials are saved with the datasource inside the
report?
What is the limitation to the number of characters that can be passed in a
URL string?
Thank you in advance,
RichardI had a similiar problem with the report server. I ended up changing
the credentials to server credentials in both the report properties and
in the properties of the report once it was on the server. Hope this
helps.

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

privatevoid Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = newDataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= newNetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

privatevoid Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = newDataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= newNetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Reporting Services?

I have created several reports in SQL Server 2005 reporting services and I am viewing those reports in my C# application using a report viewer control. I want to pass the credentials for each report through my applications. I do not want to use any web service.

Is it possible?

Any help will be appreciated!!!

TIA

YOu can use the URL Parameters to pass the username and the password, look in the BOL for more information, the syntax for that is:

prefix:datasourcename=value

as the prefix is dsu (for user) or dsp (for password)

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for your reply Jens!!!

But I am using a Report Viewer control in my application. How can I pass the username and password in this case?

|||Hi,
Hope this could help you

System.Net.CredentialCache myCache = new System.Net.CredentialCache();
myCache.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic", new System.Net.NetworkCredential("user", "pass"));

reportViewer.ShowCredentialPrompts = false;
reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache;
reportViewer.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;
reportViewer.ServerReport.ReportServerUrl ="http://localhost/reportserver";
reportViewer.ServerReport.ReportPath = "/yourReportFolder/" + "yourReportName";
reportViewer.PromptAreaCollapsed = false;
reportViewer.RefreshReport();

|||

I am trying to use the example code provided for a simialr problem but the line (in VB)

reportViewer.ServerReport.ReportServerCredentials.NetworkCredentials = myCache

always shows as read only. How do I get round this please?

|||Hi ,
I think your using report viewer web control ofr asp.net. I had same problem.
Its won't work for Microsoft.Reporting.WebForms.ReportViewer.


But i hope this link could help you..

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=373983&SiteID=1

If you found the way please post back here.


Thanks & Best Regards|||

I am attempting to secure my reports with Windows Authentication, but allow users of my application to access it from the www and supply credentials through my app. My app is a .Net 2.0 Windows SmartClient, and I am using the ReportViewer control.

I tried the following suggestion:

reportViewer1.ServerReport.ReportServerUrl = new Uri(_txtServer.Text);

reportViewer1.ServerReport.ReportPath = _listBox.Items[_listBox.SelectedIndex].ToString();

reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Remote;

CredentialCache cc = new CredentialCache();

cc.Add(new Uri("http://localhost/ReportServer/ReportService.asmx"), "Basic",

new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text));

reportViewer1.ServerReport.ReportServerCredentials.NetworkCredentials = cc;

reportViewer1.ShowCredentialPrompts = false;

reportViewer1.RefreshReport();

...But I still get "The request failed with HTTP status 401: Access Denied." I am able to authenticate with the web service directly when requesting a list of available reports like this:

ReportingService rService = new ReportingService();

rService.Credentials

= new NetworkCredential(_txtUsername.Text, _txtPassword.Text, _txtDomain.Text);

CatalogItem[] catalogItems;

catalogItems = rService.ListChildren("/", true);

Why can I pass windows credentials to the web service directly, but not through the reportViewer call to reporting services? Any help would be very much appreciated!

|||

Hi Glenn,

You might have got the solution for your problem, If not and/or for other developers who might visit this blog, please find the solution at following link. Actually you can get it work by setting ImpersonationUser instead of NetworkCredentials property.

http://blogs.msdn.com/bimusings/archive/2005/11/05/489423.aspx

|||

You can refer following link.

http://msdn2.microsoft.com/en-us/library/microsoft.reporting.webforms.ireportservercredentials(VS.80).aspx

|||

Hi, you can try this, might help.

I pass the datasource credential through ReportViewer. It is the acutal database login credential instead of a net work credential. So in my application, which login user has nothing to do with Windows

network login user, I am using my application's user id and password to connect to datasource.

By doing this way, I can view a report using diffirent user id/password as long as they exist in the actual database.

It works for me.

private void Form1_Load(object sender, EventArgs e)

{

.............................

Microsoft.Reporting.WinForms.DataSourceCredentials myCredential = new Microsoft.Reporting.WinForms.DataSourceCredentials();

myCredential.UserId = "myuserid";

myCredential.Password = "mypassword";

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

DataSourceCredentials[] myCredentials=null;

if (reportdatasourcecollection.Count > 0)

{

myCredentials = new DataSourceCredentials[reportdatasourcecollection.Count];

}

for (int iIndex = 0; iIndex < reportdatasourcecollection.Count; iIndex++)

{

ReportDataSourceInfo datasourceinfo = reportdatasourcecollection[iIndex];

myCredential.Name = datasourceinfo.Name;

myCredentials[iIndex] = myCredential;

}

this.reportViewer1.ServerReport.SetDataSourceCredentials( myCredentials );

...............................

}

|||

Hi,

I am facing the same problem.

I used ReportDataSourceInfo then it gives error that DataSource doesnt support it. Error of rsdatasource

So what should be the Connection Methods in Shared DataSource?

Nilesh

|||

Me too there's an error here.

ReportDataSourceInfoCollection reportdatasourcecollection = this.reportViewer1.ServerReport.GetDataSources();

any thoughts please?

thanks.

|||

Ishwar,

Thanks for the link. That is awesome. I got it working using the following code.

ServerReport.ReportServerCredentials.NetworkCredentials

= new NetworkCredential(properties.Username, properties.Password, properties.Domain);

Credentials in Data Sources are getting locked out of SQL

Weird one this....

Created a report. Set up a new datasource. Using credentials securely stored in server. Set up a local user on the SQL Server specifically to reference through this datasource.

Go to reportserver, run the report, and it runs fine. Run it a couple more times, runs fine. Then, all of a sudden, it fails, with the error message

  • The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775)

    This is very strange. I check the account on SQL, and it's still enabled. As it's not a domain account, it hasn't been disabled on the domain. I'm not even familiar with the phrase 'locked out'. After a bit of checking I find out about maxInvalidPasswordAttempts, whereby ASP 'locks out' accounts after 'n' wrong password attempts.

    Firstly, I'm not entering the password wrong. It's correctly entered, and stored in the report server.

    Secondly, where the heck does RS get off locking out accounts without my permission?

    I have no idea how to unlock these accounts.

    If I go ahead and create another account on the SQL, exactly the same thing happens. I can reproduce this at will. It works the first couple of times, then bang, 'locked out' again.

    Anyone got any ideas on how to modify this behavoir?I am getting the same error, all of a sudden, does anyone have a clue how to fix this?|||I am having the same problem. Does anyone know if this is a SP2 problem? Please help!

    |||Hi
    How did you create a user to access the database and this user is not a domain user? If this user is not a sql login user then the OS will lock ou the user and thus the dB lockout. If the user is a non domain user then the OS is trying netuse the account and this will definately lock it out.

    gatharia|||

    |||

    I've solved part of my troubles. I had set up a shared schedule and accidentally was using the default recurrance pattern to start every 10 minutes. This can happen very easily, as when you go to test something you might want to run it once. So... you create a new shared schedule (so you don't end up running everything on your production shared schedule). I don't know why the default is set to this recurrance pattern instead of once. Anyway... I was having the same problem as Sam Loud, but it was not caused by what I was currently doing. It was caused by this recurring "thing" that was running with the wrong password.

    Another "Thing" that caused this problem is when I tried to use shared data sources. As far as I can tell, you cannot use shared data sources when trying to use subscriptions to fileshare. I think this is a bug with reportserver. The first time it runs, it will run successfully. The second time it runs, you will get the RSLogonFailed. I don't know any way around this problem other than to just not use shared data sources.

    The other thing that has caused me problems is that when I modify a report and deploy it, make sure not to overwrite the datasource (note: this is the default setting in IIS). If you overwrite the datasource, then the userid and password that you set up on the datasource on the server gets wiped out and everything bombs out on logon and again you have a lockout situation.

    I am still having some lockouts and still working on this problem. If anyone else can let me know what their experiences are that would be very helpful. I am using subscriptions to fileshare with about 200 reports running on various schedules. Thanks!

  • Credentials in Data Sources are getting locked out of SQL

    Weird one this....

    Created a report. Set up a new datasource. Using credentials securely stored in server. Set up a local user on the SQL Server specifically to reference through this datasource.

    Go to reportserver, run the report, and it runs fine. Run it a couple more times, runs fine. Then, all of a sudden, it fails, with the error message

  • The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775) This is very strange. I check the account on SQL, and it's still enabled. As it's not a domain account, it hasn't been disabled on the domain. I'm not even familiar with the phrase 'locked out'. After a bit of checking I find out about maxInvalidPasswordAttempts, whereby ASP 'locks out' accounts after 'n' wrong password attempts.

    Firstly, I'm not entering the password wrong. It's correctly entered, and stored in the report server.

    Secondly, where the heck does RS get off locking out accounts without my permission?

    I have no idea how to unlock these accounts.

    If I go ahead and create another account on the SQL, exactly the same thing happens. I can reproduce this at will. It works the first couple of times, then bang, 'locked out' again.

    Anyone got any ideas on how to modify this behavoir?
    I am getting the same error, all of a sudden, does anyone have a clue how to fix this?|||I am having the same problem. Does anyone know if this is a SP2 problem? Please help!|||Hi
    How did you create a user to access the database and this user is not a domain user? If this user is not a sql login user then the OS will lock ou the user and thus the dB lockout. If the user is a non domain user then the OS is trying netuse the account and this will definately lock it out.

    gatharia
    |||

    I've solved part of my troubles. I had set up a shared schedule and accidentally was using the default recurrance pattern to start every 10 minutes. This can happen very easily, as when you go to test something you might want to run it once. So... you create a new shared schedule (so you don't end up running everything on your production shared schedule). I don't know why the default is set to this recurrance pattern instead of once. Anyway... I was having the same problem as Sam Loud, but it was not caused by what I was currently doing. It was caused by this recurring "thing" that was running with the wrong password.

    Another "Thing" that caused this problem is when I tried to use shared data sources. As far as I can tell, you cannot use shared data sources when trying to use subscriptions to fileshare. I think this is a bug with reportserver. The first time it runs, it will run successfully. The second time it runs, you will get the RSLogonFailed. I don't know any way around this problem other than to just not use shared data sources.

    The other thing that has caused me problems is that when I modify a report and deploy it, make sure not to overwrite the datasource (note: this is the default setting in IIS). If you overwrite the datasource, then the userid and password that you set up on the datasource on the server gets wiped out and everything bombs out on logon and again you have a lockout situation.

    I am still having some lockouts and still working on this problem. If anyone else can let me know what their experiences are that would be very helpful. I am using subscriptions to fileshare with about 200 reports running on various schedules. Thanks!

    |||

    The final (and most difficult to resolve) problem that was causing the "logon Failed" and then account lockout problem(s) was related to the windows account that expired (it was set up to expire in 90 days). Since I used this userid when setting up my report subscriptions, all of my subscriptions failed with invalid login and then the account was locked out. When the account userid was reactivated in WINDOWS with the same password, still all of the subscriptions failed on login. This was very frustrating because the main report services account was getting locked every day and nobody could get to the report server and all the report jobs were failing. I tried going into each report subscription and retyping the userid and password (which were valid), but I still got the invalid login. After 3 weeks of frustration and trying different things, I have discovered that what you have to do is 1) go in to the subscription general screen and change the userid and password to something invalid and totally different 2) go out of the subscription general screen (to save your changes) and 3) go back into the subscription general screen and re-type the correct userid and password. This resolved all of my login and lockout problems with the subscriptions and writing to datashare. I hope that this helps anyone else out there who might be struggling with this same issue/problem with reportserver and subscriptions. It is obviously a bug.

  • Credentials in Data Sources are getting locked out of SQL

    Weird one this....

    Created a report. Set up a new datasource. Using credentials securely stored in server. Set up a local user on the SQL Server specifically to reference through this datasource.

    Go to reportserver, run the report, and it runs fine. Run it a couple more times, runs fine. Then, all of a sudden, it fails, with the error message

  • The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775) This is very strange. I check the account on SQL, and it's still enabled. As it's not a domain account, it hasn't been disabled on the domain. I'm not even familiar with the phrase 'locked out'. After a bit of checking I find out about maxInvalidPasswordAttempts, whereby ASP 'locks out' accounts after 'n' wrong password attempts.

    Firstly, I'm not entering the password wrong. It's correctly entered, and stored in the report server.

    Secondly, where the heck does RS get off locking out accounts without my permission?

    I have no idea how to unlock these accounts.

    If I go ahead and create another account on the SQL, exactly the same thing happens. I can reproduce this at will. It works the first couple of times, then bang, 'locked out' again.

    Anyone got any ideas on how to modify this behavoir?
    I am getting the same error, all of a sudden, does anyone have a clue how to fix this?|||I am having the same problem. Does anyone know if this is a SP2 problem? Please help!|||Hi
    How did you create a user to access the database and this user is not a domain user? If this user is not a sql login user then the OS will lock ou the user and thus the dB lockout. If the user is a non domain user then the OS is trying netuse the account and this will definately lock it out.

    gatharia
    |||

    I've solved part of my troubles. I had set up a shared schedule and accidentally was using the default recurrance pattern to start every 10 minutes. This can happen very easily, as when you go to test something you might want to run it once. So... you create a new shared schedule (so you don't end up running everything on your production shared schedule). I don't know why the default is set to this recurrance pattern instead of once. Anyway... I was having the same problem as Sam Loud, but it was not caused by what I was currently doing. It was caused by this recurring "thing" that was running with the wrong password.

    Another "Thing" that caused this problem is when I tried to use shared data sources. As far as I can tell, you cannot use shared data sources when trying to use subscriptions to fileshare. I think this is a bug with reportserver. The first time it runs, it will run successfully. The second time it runs, you will get the RSLogonFailed. I don't know any way around this problem other than to just not use shared data sources.

    The other thing that has caused me problems is that when I modify a report and deploy it, make sure not to overwrite the datasource (note: this is the default setting in IIS). If you overwrite the datasource, then the userid and password that you set up on the datasource on the server gets wiped out and everything bombs out on logon and again you have a lockout situation.

    I am still having some lockouts and still working on this problem. If anyone else can let me know what their experiences are that would be very helpful. I am using subscriptions to fileshare with about 200 reports running on various schedules. Thanks!

    |||

    The final (and most difficult to resolve) problem that was causing the "logon Failed" and then account lockout problem(s) was related to the windows account that expired (it was set up to expire in 90 days). Since I used this userid when setting up my report subscriptions, all of my subscriptions failed with invalid login and then the account was locked out. When the account userid was reactivated in WINDOWS with the same password, still all of the subscriptions failed on login. This was very frustrating because the main report services account was getting locked every day and nobody could get to the report server and all the report jobs were failing. I tried going into each report subscription and retyping the userid and password (which were valid), but I still got the invalid login. After 3 weeks of frustration and trying different things, I have discovered that what you have to do is 1) go in to the subscription general screen and change the userid and password to something invalid and totally different 2) go out of the subscription general screen (to save your changes) and 3) go back into the subscription general screen and re-type the correct userid and password. This resolved all of my login and lockout problems with the subscriptions and writing to datashare. I hope that this helps anyone else out there who might be struggling with this same issue/problem with reportserver and subscriptions. It is obviously a bug.

  • Credentials in Data Sources are getting locked out of SQL

    Weird one this....

    Created a report. Set up a new datasource. Using credentials securely stored in server. Set up a local user on the SQL Server specifically to reference through this datasource.

    Go to reportserver, run the report, and it runs fine. Run it a couple more times, runs fine. Then, all of a sudden, it fails, with the error message

  • The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775) This is very strange. I check the account on SQL, and it's still enabled. As it's not a domain account, it hasn't been disabled on the domain. I'm not even familiar with the phrase 'locked out'. After a bit of checking I find out about maxInvalidPasswordAttempts, whereby ASP 'locks out' accounts after 'n' wrong password attempts.

    Firstly, I'm not entering the password wrong. It's correctly entered, and stored in the report server.

    Secondly, where the heck does RS get off locking out accounts without my permission?

    I have no idea how to unlock these accounts.

    If I go ahead and create another account on the SQL, exactly the same thing happens. I can reproduce this at will. It works the first couple of times, then bang, 'locked out' again.

    Anyone got any ideas on how to modify this behavoir?
    I am getting the same error, all of a sudden, does anyone have a clue how to fix this?|||I am having the same problem. Does anyone know if this is a SP2 problem? Please help!|||Hi
    How did you create a user to access the database and this user is not a domain user? If this user is not a sql login user then the OS will lock ou the user and thus the dB lockout. If the user is a non domain user then the OS is trying netuse the account and this will definately lock it out.

    gatharia
    |||

    I've solved part of my troubles. I had set up a shared schedule and accidentally was using the default recurrance pattern to start every 10 minutes. This can happen very easily, as when you go to test something you might want to run it once. So... you create a new shared schedule (so you don't end up running everything on your production shared schedule). I don't know why the default is set to this recurrance pattern instead of once. Anyway... I was having the same problem as Sam Loud, but it was not caused by what I was currently doing. It was caused by this recurring "thing" that was running with the wrong password.

    Another "Thing" that caused this problem is when I tried to use shared data sources. As far as I can tell, you cannot use shared data sources when trying to use subscriptions to fileshare. I think this is a bug with reportserver. The first time it runs, it will run successfully. The second time it runs, you will get the RSLogonFailed. I don't know any way around this problem other than to just not use shared data sources.

    The other thing that has caused me problems is that when I modify a report and deploy it, make sure not to overwrite the datasource (note: this is the default setting in IIS). If you overwrite the datasource, then the userid and password that you set up on the datasource on the server gets wiped out and everything bombs out on logon and again you have a lockout situation.

    I am still having some lockouts and still working on this problem. If anyone else can let me know what their experiences are that would be very helpful. I am using subscriptions to fileshare with about 200 reports running on various schedules. Thanks!

    |||

    The final (and most difficult to resolve) problem that was causing the "logon Failed" and then account lockout problem(s) was related to the windows account that expired (it was set up to expire in 90 days). Since I used this userid when setting up my report subscriptions, all of my subscriptions failed with invalid login and then the account was locked out. When the account userid was reactivated in WINDOWS with the same password, still all of the subscriptions failed on login. This was very frustrating because the main report services account was getting locked every day and nobody could get to the report server and all the report jobs were failing. I tried going into each report subscription and retyping the userid and password (which were valid), but I still got the invalid login. After 3 weeks of frustration and trying different things, I have discovered that what you have to do is 1) go in to the subscription general screen and change the userid and password to something invalid and totally different 2) go out of the subscription general screen (to save your changes) and 3) go back into the subscription general screen and re-type the correct userid and password. This resolved all of my login and lockout problems with the subscriptions and writing to datashare. I hope that this helps anyone else out there who might be struggling with this same issue/problem with reportserver and subscriptions. It is obviously a bug.

  • Credentials in Data Sources are getting locked out of SQL

    Weird one this....

    Created a report. Set up a new datasource. Using credentials securely stored in server. Set up a local user on the SQL Server specifically to reference through this datasource.

    Go to reportserver, run the report, and it runs fine. Run it a couple more times, runs fine. Then, all of a sudden, it fails, with the error message

  • The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775)

    This is very strange. I check the account on SQL, and it's still enabled. As it's not a domain account, it hasn't been disabled on the domain. I'm not even familiar with the phrase 'locked out'. After a bit of checking I find out about maxInvalidPasswordAttempts, whereby ASP 'locks out' accounts after 'n' wrong password attempts.

    Firstly, I'm not entering the password wrong. It's correctly entered, and stored in the report server.

    Secondly, where the heck does RS get off locking out accounts without my permission?

    I have no idea how to unlock these accounts.

    If I go ahead and create another account on the SQL, exactly the same thing happens. I can reproduce this at will. It works the first couple of times, then bang, 'locked out' again.

    Anyone got any ideas on how to modify this behavoir?
    I am getting the same error, all of a sudden, does anyone have a clue how to fix this?|||I am having the same problem. Does anyone know if this is a SP2 problem? Please help!

    |||Hi
    How did you create a user to access the database and this user is not a domain user? If this user is not a sql login user then the OS will lock ou the user and thus the dB lockout. If the user is a non domain user then the OS is trying netuse the account and this will definately lock it out.

    gatharia
    |||

    |||

    I've solved part of my troubles. I had set up a shared schedule and accidentally was using the default recurrance pattern to start every 10 minutes. This can happen very easily, as when you go to test something you might want to run it once. So... you create a new shared schedule (so you don't end up running everything on your production shared schedule). I don't know why the default is set to this recurrance pattern instead of once. Anyway... I was having the same problem as Sam Loud, but it was not caused by what I was currently doing. It was caused by this recurring "thing" that was running with the wrong password.

    Another "Thing" that caused this problem is when I tried to use shared data sources. As far as I can tell, you cannot use shared data sources when trying to use subscriptions to fileshare. I think this is a bug with reportserver. The first time it runs, it will run successfully. The second time it runs, you will get the RSLogonFailed. I don't know any way around this problem other than to just not use shared data sources.

    The other thing that has caused me problems is that when I modify a report and deploy it, make sure not to overwrite the datasource (note: this is the default setting in IIS). If you overwrite the datasource, then the userid and password that you set up on the datasource on the server gets wiped out and everything bombs out on logon and again you have a lockout situation.

    I am still having some lockouts and still working on this problem. If anyone else can let me know what their experiences are that would be very helpful. I am using subscriptions to fileshare with about 200 reports running on various schedules. Thanks!

    |||

    The final (and most difficult to resolve) problem that was causing the "logon Failed" and then account lockout problem(s) was related to the windows account that expired (it was set up to expire in 90 days). Since I used this userid when setting up my report subscriptions, all of my subscriptions failed with invalid login and then the account was locked out. When the account userid was reactivated in WINDOWS with the same password, still all of the subscriptions failed on login. This was very frustrating because the main report services account was getting locked every day and nobody could get to the report server and all the report jobs were failing. I tried going into each report subscription and retyping the userid and password (which were valid), but I still got the invalid login. After 3 weeks of frustration and trying different things, I have discovered that what you have to do is 1) go in to the subscription general screen and change the userid and password to something invalid and totally different 2) go out of the subscription general screen (to save your changes) and 3) go back into the subscription general screen and re-type the correct userid and password. This resolved all of my login and lockout problems with the subscriptions and writing to datashare. I hope that this helps anyone else out there who might be struggling with this same issue/problem with reportserver and subscriptions. It is obviously a bug.

  • credentials

    I am using RS2000. I have created some reports and publish to the server. A
    folder has been created at /home/test1 in report manger and granted the
    access right to user A.
    I created a .net application with impersonation = false, how can I call the
    reports under test1 inside this application by using the RS2000 control? what
    I mean is how to pass the A's credential to reporting services so that I can
    access the report.
    Can anyone give me some suggestion? Thanks a lot!Hi, Ry
    When you say "using the RS2000 control" do you mean the sample report
    viewer control for ASP.NET?
    If so, then the control should be using the URL access method to create
    HTTP GET requests (it creates URL querystrings) that fetch the report
    and display them in an IFRAME.
    So when the control points the IFRAME to the ReportServer and folder
    where the report is located, it's the same as if the current user
    opened a browser and tried to view the ReportServer directly
    (http://servername/ReportServer?/home/test1/testReport¶m1=SomeValue).
    The Report Server uses windows authentication, so your application is
    not actually performing the authentication for the reports and folders,
    it's all done by the Report Server.
    If you were using the RS web service to make proxy calls to render the
    report, then you would need to provide user context information to the
    Web Service, so it would authenticate. You would use
    DefaultCredentials to pass your current application's user to the
    Report Server via the web service Credentials property.
    Hope that points you in the right direction.
    Regards,
    Thiago Silva
    MCAD.NET
    Ry wrote:
    > I am using RS2000. I have created some reports and publish to the server. A
    > folder has been created at /home/test1 in report manger and granted the
    > access right to user A.
    > I created a .net application with impersonation = false, how can I call the
    > reports under test1 inside this application by using the RS2000 control? what
    > I mean is how to pass the A's credential to reporting services so that I can
    > access the report.
    > Can anyone give me some suggestion? Thanks a lot!

    CRecordset.Close() causes exception

    Hi,
    I'm having problems with VC++ 6.0 reading an Access 2000 database.
    CRecordset::Close() throws an exception. I've created a simple test
    dialog which does an open and close of a CRecordset. The database has
    one table called 'Addresses' in it. The CAddressSet was created by the
    Class Wizard.
    void CDatabaseDlg::OnOK()
    {
    CDatabase db;
    db.Open(NULL,FALSE,FALSE,"DSN=c:\\dev\\db1.mdb");
    // Construct the snapshot object
    CAddressSet rsAddr( NULL );
    // Set options if desired, then open the recordset
    rsAddr.Open(CRecordset::snapshot, NULL, CRecordset::none );
    rsAddr.Close( );
    db.Close( );
    Dialog::OnOK();
    }
    The Close method throws on the AFX_SQP_SERVER line below:
    RETCODE nRetCode;
    if (m_hstmt != SQL_NULL_HSTMT)
    {
    AFX_SQL_SYNC(::SQLFreeStmt(m_hstmt, SQL_DROP));
    m_hstmt = SQL_NULL_HSTMT;
    }
    This program just couldn't get any simpler - and yet it doesn't work!
    Anybody got any clue as to why?
    Many thanks,
    Jeremy
    Recordset is not connected to database? Recordset is completely empty?
    etc?
    Free software - Baxter Codeworks www.baxcode.com
    "Jezzer" <Jemtaylor@.yahoo.com> wrote in message
    news:1115894836.839503.104060@.g14g2000cwa.googlegr oups.com...
    > Hi,
    > I'm having problems with VC++ 6.0 reading an Access 2000 database.
    > CRecordset::Close() throws an exception. I've created a simple test
    > dialog which does an open and close of a CRecordset. The database has
    > one table called 'Addresses' in it. The CAddressSet was created by the
    > Class Wizard.
    > void CDatabaseDlg::OnOK()
    > {
    > CDatabase db;
    > db.Open(NULL,FALSE,FALSE,"DSN=c:\\dev\\db1.mdb");
    > // Construct the snapshot object
    > CAddressSet rsAddr( NULL );
    > // Set options if desired, then open the recordset
    > rsAddr.Open(CRecordset::snapshot, NULL, CRecordset::none );
    >
    > rsAddr.Close( );
    > db.Close( );
    >
    > Dialog::OnOK();
    > }
    > The Close method throws on the AFX_SQP_SERVER line below:
    > RETCODE nRetCode;
    > if (m_hstmt != SQL_NULL_HSTMT)
    > {
    > AFX_SQL_SYNC(::SQLFreeStmt(m_hstmt, SQL_DROP));
    > m_hstmt = SQL_NULL_HSTMT;
    > }
    > This program just couldn't get any simpler - and yet it doesn't work!
    > Anybody got any clue as to why?
    > Many thanks,
    > Jeremy
    >
    |||Yes, I see why it might look like that with the NULL in the CRecordSet
    declaration. I've defined my test database using ODBC manager and the
    GetDefaultConnect() method looks like this:
    CString CAddressSet::GetDefaultConnect()
    {
    return _T("ODBC;DSN=db1");
    }
    where 'db1' is my database with the Addresses table in it. This was all
    put there by the wizard.
    I have had this same test retrieving the data succesfully but I took
    that stuff out to make the example less cluttered.
    It's just the Close that crashes whether you retrieve stuff or not.
    cheers anyway...
    Jeremy
    |||Hi all,
    I've made some progress with this problem now. I've discovered that
    CRecordSet::Close() only crashes when running under Visual Studio -
    when the exe is run stand-alone it works fine. I can remove the 'fudge'
    and it loads the DB Ok.
    The 'fudge' I use where I set m_hstmnt = SQL_NULL_HSTMT in the
    ::Close() method means that when debugging the method does not crash -
    but it seems to cause the Access interface to run *extremely* slowly.
    No CPU being used - just seems to be waiting an awful lot. So I suspect
    that whatever is being freed by the 'SQLFreeStmt' call is getting
    clogged. My hunch is that Access or ODBC is waiting for a space in some
    buffer to open up and eventually decides to remove the oldest 'thing' -
    whatever that is.
    A search of Google Groups shows that lots of people have had this
    problem - is there nobody out there that knows the answer?
    cheers
    Jeremy