Showing posts with label keller. Show all posts
Showing posts with label keller. Show all posts

Wednesday, March 21, 2012

Problems with Parameters (C#)

I am passing parameters from Bryan Keller's C# program that has been
mentioned here many times to my report. I get the following error:
Default value or value provided for the report parameter 'fromclient' is
not a valid value.
The execution log shows 'rsInvalidReportParameter'.
'fromclient is a string value and it is the 3rd parameter of seven. The
first two are boolean, and I pass them as "0" and "1".
I don't seem to get past this point. What am I doing wrong?
GerhardJust check the Report parameters and see what datatype is
set for FromClient.
May be its set to something else other than string
>--Original Message--
>I am passing parameters from Bryan Keller's C# program
that has been
>mentioned here many times to my report. I get the
following error:
> Default value or value provided for the report
parameter 'fromclient' is
>not a valid value.
>The execution log shows 'rsInvalidReportParameter'.
>'fromclient is a string value and it is the 3rd parameter
of seven. The
>first two are boolean, and I pass them as "0" and "1".
>I don't seem to get past this point. What am I doing wrong?
>Gerhard
>
>.
>|||It's string but it is from a query (dropdown box). Maybe that's the
problem?
Gerhard
"Ravi" <ravikantkv@.rediffmail.com> wrote in message
news:5a3301c491d9$db50e8a0$a601280a@.phx.gbl...
> Just check the Report parameters and see what datatype is
> set for FromClient.
> May be its set to something else other than string
> >--Original Message--
> >I am passing parameters from Bryan Keller's C# program
> that has been
> >mentioned here many times to my report. I get the
> following error:
> > Default value or value provided for the report
> parameter 'fromclient' is
> >not a valid value.
> >The execution log shows 'rsInvalidReportParameter'.
> >
> >'fromclient is a string value and it is the 3rd parameter
> of seven. The
> >first two are boolean, and I pass them as "0" and "1".
> >I don't seem to get past this point. What am I doing wrong?
> >Gerhard
> >
> >
> >.
> >

Wednesday, March 7, 2012

Problems with C# Sample to Print Reports

I am having permission problems with the sample report printing program from
Bryan Keller. (http://www.csharphelp.com/archives3/archive545.html)
The DefaultCredentials from the CredentialCache certainly has no data, and I
don't seem to be able to get valid data into the cache
Not sure about the relative path of the report either. I am running against
my own report, since I don't have the samples installed. I am using:
/Report Project1/118-2 as a path.
Don't know if that is correct, but that is what I see when I run it in the
browser. Except the '/' char turns into %2F, and the space into a '+'.
So it's %2FReport+Project1%2F118-2 in the browser.
Has anybody else tried this sample program with their own reports?
GerhardThe path of a report is relative to the root on the Report
Server.
So in the Report Manager if you see your report , lets say
report1 under the folder Report Project1 then the path of
your report is Report Project1/report1.
>--Original Message--
>I am having permission problems with the sample report
printing program from
>Bryan Keller.
(http://www.csharphelp.com/archives3/archive545.html)
>The DefaultCredentials from the CredentialCache certainly
has no data, and I
>don't seem to be able to get valid data into the cache
>Not sure about the relative path of the report either. I
am running against
>my own report, since I don't have the samples installed.
I am using:
>/Report Project1/118-2 as a path.
>Don't know if that is correct, but that is what I see
when I run it in the
>browser. Except the '/' char turns into %2F, and the
space into a '+'.
>So it's %2FReport+Project1%2F118-2 in the browser.
>Has anybody else tried this sample program with their own
reports?
>Gerhard
>
>.
>|||Ok, thanks, Ravi, that makes sense.
What about the DefaultCredentials? There are null strings for user/pw and
domain right now.
How do I get my domain credentials into the cache?
Gerhard
"Ravi" <anonymous@.discussions.microsoft.com> wrote in message
news:253e01c48e1e$c8cae640$a601280a@.phx.gbl...
> The path of a report is relative to the root on the Report
> Server.
> So in the Report Manager if you see your report , lets say
> report1 under the folder Report Project1 then the path of
> your report is Report Project1/report1.
> >--Original Message--
> >I am having permission problems with the sample report
> printing program from
> >Bryan Keller.
> (http://www.csharphelp.com/archives3/archive545.html)
> >
> >The DefaultCredentials from the CredentialCache certainly
> has no data, and I
> >don't seem to be able to get valid data into the cache
> >
> >Not sure about the relative path of the report either. I
> am running against
> >my own report, since I don't have the samples installed.
> I am using:
> >/Report Project1/118-2 as a path.
> >Don't know if that is correct, but that is what I see
> when I run it in the
> >browser. Except the '/' char turns into %2F, and the
> space into a '+'.
> >So it's %2FReport+Project1%2F118-2 in the browser.
> >
> >Has anybody else tried this sample program with their own
> reports?
> >
> >Gerhard
> >
> >
> >.
> >|||Ok, got the path and credentials problem solved. I can elaborated if it
will help others.
Path is: /folder/report
Credentials is: rs.Credentials = new
NetworkCredential("user","pw","domain")
DefaultCredentials may work if you're on a Lan, I'm on a VPN.
But now the question is: How do I pass parameters, as part of the URL? And
syntax?
Yeah I know, I'm a pain. <g> Sorry, this is all hitting me a little fast
too.
Gerhard
"Ravi" <anonymous@.discussions.microsoft.com> wrote in message
news:253e01c48e1e$c8cae640$a601280a@.phx.gbl...
> The path of a report is relative to the root on the Report
> Server.
> So in the Report Manager if you see your report , lets say
> report1 under the folder Report Project1 then the path of
> your report is Report Project1/report1.
> >--Original Message--
> >I am having permission problems with the sample report
> printing program from
> >Bryan Keller.
> (http://www.csharphelp.com/archives3/archive545.html)
> >
> >The DefaultCredentials from the CredentialCache certainly
> has no data, and I
> >don't seem to be able to get valid data into the cache
> >
> >Not sure about the relative path of the report either. I
> am running against
> >my own report, since I don't have the samples installed.
> I am using:
> >/Report Project1/118-2 as a path.
> >Don't know if that is correct, but that is what I see
> when I run it in the
> >browser. Except the '/' char turns into %2F, and the
> space into a '+'.
> >So it's %2FReport+Project1%2F118-2 in the browser.
> >
> >Has anybody else tried this sample program with their own
> reports?
> >
> >Gerhard
> >
> >
> >.
> >|||> Has anybody else tried this sample program with their own reports?
After making modifications for credencials I have used this code
successfully. Thursday I will try running it as a assembly from a web
page - we shall see. Looks good.
dlr
"Gerhard Paulman" <gerhardp@.inch.com> wrote in message
news:%23M$IbFejEHA.3428@.TK2MSFTNGP11.phx.gbl...
> I am having permission problems with the sample report printing program
from
> Bryan Keller. (http://www.csharphelp.com/archives3/archive545.html)
> The DefaultCredentials from the CredentialCache certainly has no data, and
I
> don't seem to be able to get valid data into the cache
> Not sure about the relative path of the report either. I am running
against
> my own report, since I don't have the samples installed. I am using:
> /Report Project1/118-2 as a path.
> Don't know if that is correct, but that is what I see when I run it in the
> browser. Except the '/' char turns into %2F, and the space into a '+'.
> So it's %2FReport+Project1%2F118-2 in the browser.
> Has anybody else tried this sample program with their own reports?
> Gerhard
>