how to show picture from database in RTC

julkifli33
Member Posts: 1,092
hi all
i'm using NAV 2009 R2
i want to show company logo,which is uploaded through company information
how to show it in RTC reports at the header?
thanks
i'm using NAV 2009 R2
i want to show company logo,which is uploaded through company information
how to show it in RTC reports at the header?
thanks
0
Comments
-
-
mohana_cse06 wrote:Just follow this link :thumbsup:
http://blogs.msdn.com/b/nav-reporting/archive/2009/02/05/how-to-add-a-company-picture-to-a-report.aspx0 -
mohana_cse06 wrote:Just follow this link :thumbsup:
http://blogs.msdn.com/b/nav-reporting/archive/2009/02/05/how-to-add-a-company-picture-to-a-report.aspx
but why still not working0 -
i try to change this code become visible
=Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
but the result is #Error0 -
julkifli33 wrote:i try to change this code become visible
=Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
but the result is #Error
if it shows "#Error", it means that there's something wrong.
1. Are you sure you've passed the right value to the function Convet.ToBase64String?
2. Did you call CalcFields for Picture field?~Rik~
It works as expected... More or Less...0 -
Troubles In Paradise wrote:julkifli33 wrote:i try to change this code become visible
=Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
but the result is #Error
if it shows "#Error", it means that there's something wrong.
1. Are you sure you've passed the right value to the function Convet.ToBase64String?
2. Did you call CalcFields for Picture field?
1. in body... i add textbox. and then the expression i add=Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
2. yes... i add in onPreReportCompanyInfo.Calcfields(Picture);
for your information Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
--> the bold one in expression is still red underlined0 -
julkifli33 wrote:[for your information Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
--> the bold one in expression is still red underlined
This is "normal", also if it will show the picture it will remain red underlined.
Did you try to rewrite code in the textbox that containts convertion? if haven't done yet, try using the assist edit...~Rik~
It works as expected... More or Less...0 -
Troubles In Paradise wrote:julkifli33 wrote:[for your information Convert.ToBase64String(Fields!CompanyInfo_Picture.Value)
--> the bold one in expression is still red underlined
This is "normal", also if it will show the picture it will remain red underlined.
Did you try to rewrite code in the textbox that containts convertion? if haven't done yet, try using the assist edit...
i attach my steps and result
please take a look
what did i miss?0 -
All seems correct.
Could you attach a screenshot of the "About this Report" please?
The idea I have is that DataSet hasn't the value of the Picture field in the moment you do the convertion.~Rik~
It works as expected... More or Less...0 -
Troubles In Paradise wrote:All seems correct.
Could you attach a screenshot of the "About this Report" please?
The idea I have is that DataSet hasn't the value of the Picture field in the moment you do the convertion.
what do you mean "About This Report" ?
in classic mode it showed the picture
but i added calcfields in section0 -
After have launched the report press CTRL+ALT+F1.
Or use the question mark:
after this the system will ask you to redo it and then you will see the DataSet.but i added calcfields in section
You said before that you placed calcfields in section... hope not in a section trigger...~Rik~
It works as expected... More or Less...0 -
Troubles In Paradise wrote:After have launched the report press CTRL+ALT+F1.
Or use the question mark:
after this the system will ask you to redo it and then you will see the DataSet.but i added calcfields in section
You said before that you placed calcfields in section... hope not in a section trigger...
i add calcfields twice
1 in section... (just for testing classic), and another one is in onPreReport
here the attachment for About This Report0 -
This is the problem... As you can see from your screenshot the Companyinfo_Picture hasn't value (otherwise you would see '*' in its column, since it's a BLOB), so when you pass it to convertion function it has nothing to convert.
In which section you placed the Image in classic report?~Rik~
It works as expected... More or Less...0 -
and don't forget to call CompanyInfo.GET somewhere before the CALCFIELDS-Mihail- [MCTS]0
-
Troubles In Paradise wrote:This is the problem... As you can see from your screenshot the Companyinfo_Picture hasn't value (otherwise you would see '*' in its column, since it's a BLOB), so when you pass it to convertion function it has nothing to convert.
In which section you placed the Image in classic report?
and i put the picture box in classic at PageLoop Header (1)0 -
mihail_kolev wrote:and don't forget to call CompanyInfo.GET somewhere before the CALCFIELDS
Report - OnPreReport() CompanyInfo.GET; CompanyInfo.CALCFIELDS(Picture);
0 -
Make sure thatCompanyInfo.GET;0
-
I suggest you to create a an Header Section for the Purchase Header data Item.
Put you picture in this section...~Rik~
It works as expected... More or Less...0 -
in classic layout, make sure you use "Picture Box" control, not "Image" (I had that problem before and took me a week or two to notice that)-Mihail- [MCTS]0
-
mihail_kolev wrote:in classic layout, make sure you use "Picture Box" control, not "Image" (I had that problem before and took me a week or two to notice that)
yes i already put in picture box0 -
Troubles In Paradise wrote:I suggest you to create a an Header Section for the Purchase Header data Item.
Put you picture in this section...0 -
i add Companyinfo.calcfields(picture)
in pageloop dataitem
now I am able to show in the report
thanks0 -
Hi ... can i add one more pic from company information?
i already follow the steps
but the picture always the same (pic 1 and pic 2 in RS report)0 -
julkifli33 wrote:Hi ... can i add one more pic from company information?
i already follow the steps
but the picture always the same (pic 1 and pic 2 in RS report)
You will see that there're 3 Logos in the header.
For each Picture there's a textbox in the body with its "Convert.ToBase64String".
In the Header there's a "SetPicture" for each Logo, with an increasing number (SetPicture(1,...), SetPicture(2,...) and so on...).
In the Header each Picture has its own "GetPicture", that calls the corresponding "SetPicture".~Rik~
It works as expected... More or Less...0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions