I know you cannot directly place data fields in the headers or footers
with SQL server reporting services. You can trick it by putting a
hidden text field in the body of the report and referencing it in the
header or footer by using ReportItems.
How do you display SQL server Image data fields in headers or footers?
I tried using Report parameters, but that caused unpredictable results
with my text fields. Report parameters don't have an option for Image
fields for the data type which makes sense.
Appreciate your help.You need encode image in the parameter, and decode it later
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"jtabar" <john.tabar@.usa.net> wrote in message
news:b62a5355.0409231320.3b340324@.posting.google.com...
>I know you cannot directly place data fields in the headers or footers
> with SQL server reporting services. You can trick it by putting a
> hidden text field in the body of the report and referencing it in the
> header or footer by using ReportItems.
> How do you display SQL server Image data fields in headers or footers?
> I tried using Report parameters, but that caused unpredictable results
> with my text fields. Report parameters don't have an option for Image
> fields for the data type which makes sense.
> Appreciate your help.|||Lev, tnx for your help. With some help from Microsoft support, I got
it to work by using a textbox in the body of the report and setting
the value to:
=System.Convert.ToBase64String(First(Fields!MyImage.Value, "MyDB"))
Then setup an image field in the footer and set the following:
- MIMEType: image/bmp
- Source: Database
- Value: =System.Convert.FromBase64String(ReportItems!Mytextbox.value)
I couldn't get the parameter to work. Wasn't sure how to do what you
suggested by "You need encode image in the parameter" in your note.
"Lev Semenets [MSFT]" <levs@.microsoft.com> wrote in message news:<usSu5yfoEHA.2948@.TK2MSFTNGP11.phx.gbl>...
> You need encode image in the parameter, and decode it later
> --
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "jtabar" <john.tabar@.usa.net> wrote in message
> news:b62a5355.0409231320.3b340324@.posting.google.com...
> >I know you cannot directly place data fields in the headers or footers
> > with SQL server reporting services. You can trick it by putting a
> > hidden text field in the body of the report and referencing it in the
> > header or footer by using ReportItems.
> >
> > How do you display SQL server Image data fields in headers or footers?
> >
> > I tried using Report parameters, but that caused unpredictable results
> > with my text fields. Report parameters don't have an option for Image
> > fields for the data type which makes sense.
> >
> > Appreciate your help.|||It is similar technique, where parameter is used instead of hidden textbox
to pass encoded image
Create calculated field "MyEncodedImage" and set expression to
=System.Convert.ToBase64String(Fields!MyImage.Value)
Create report parameter "MyEncodedImageParam", set its type to String, erase
Prompt, clear Allow Null and Allow Blank checkboxes, set default value "from
query" and select MyDB as dataset and MyEncodedImage as value field.
Set value for your image in the footer to
=System.Convert.FromBase64String(Parameters!MyEncodedImageParam.value)
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"jtabar" <john.tabar@.usa.net> wrote in message
news:b62a5355.0409241237.53141003@.posting.google.com...
> Lev, tnx for your help. With some help from Microsoft support, I got
> it to work by using a textbox in the body of the report and setting
> the value to:
> =System.Convert.ToBase64String(First(Fields!MyImage.Value, "MyDB"))
> Then setup an image field in the footer and set the following:
> - MIMEType: image/bmp
> - Source: Database
> - Value: =System.Convert.FromBase64String(ReportItems!Mytextbox.value)
> I couldn't get the parameter to work. Wasn't sure how to do what you
> suggested by "You need encode image in the parameter" in your note.
>
> "Lev Semenets [MSFT]" <levs@.microsoft.com> wrote in message
> news:<usSu5yfoEHA.2948@.TK2MSFTNGP11.phx.gbl>...
>> You need encode image in the parameter, and decode it later
>> --
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>> "jtabar" <john.tabar@.usa.net> wrote in message
>> news:b62a5355.0409231320.3b340324@.posting.google.com...
>> >I know you cannot directly place data fields in the headers or footers
>> > with SQL server reporting services. You can trick it by putting a
>> > hidden text field in the body of the report and referencing it in the
>> > header or footer by using ReportItems.
>> >
>> > How do you display SQL server Image data fields in headers or footers?
>> >
>> > I tried using Report parameters, but that caused unpredictable results
>> > with my text fields. Report parameters don't have an option for Image
>> > fields for the data type which makes sense.
>> >
>> > Appreciate your help.
Friday, February 24, 2012
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment