Deploy Crystal Report Application

| March 7, 2012 | 13 Comments

Learn how to deploy crystal report application on production server. Why the same code works fine on development server. But get fail on production server. We would try to understand crystal report issue faced by most of the developers while deployment of crystal report apps.

I googled lot for same issue but information was scattered. And most it was not explaining exactly how to do? Before I start I would like to make excuse that I’m not so much well versed with crystal report. But still I can share collectively that can help anybody in deployment. This article deals especially with Crystal Report Assembly version 13.0.2000.0 (CR for VS 2010). But I hope it would work in any other case.

1. When we develop crystal report application on development server and test, it works fine. Because on local server assemblies required are available to application. Let us take look over code snippet of web.config, which shows assembly added for crystal report:

<assemblies>
                <add assembly="CrystalDecisions.CrystalReports.Engine, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304">
                <add assembly="CrystalDecisions.ReportSource, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304">
                <add assembly="CrystalDecisions.Shared, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304">
                <add assembly="CrystalDecisions.Web, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304">
                <add assembly="CrystalDecisions.ReportAppServer.ClientDoc, Version=13.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304">
            </add>
</add></add></add></add></assemblies>

So these assemblies are referenced from GAC (Global Assembly Cache). But if you try to deploy same application on remote server, the application throws errors of different types because same assemblies are not there in GAC.

Many sites and knowledgeable developers share that by installing appropriate CR runtime on remote server, the problem gets resolved. You can download same according to requirements at Crystal Reports v. 9.1 to CRVS2010 Runtime Distribution.

2. If you don’t have access to remote share then you might have the problem in implementing above mentioned solution. In that case you can just copy necessary dll’s required by your application in bin folder. And it will work fine.

When we install CR for VS 2010 on PC, the assemblies needed for application gets copied to directory C:\Program Files\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet
. As we have seen in above Web.config assemblies named, just copy those assemblies in Bin folder from above directory, and then remove the assemblies element from web.config.The application would still work nicely.

3. Sometimes application would still not work due to reasons. Solution for same:
(a) Set FULL TRUST permission on root folder.
(b) LOCAL SERVICE permission must be set on application pool.
(c) Make sure the aspnet_client folder exists in root folder.
(d) Grant modify permissions on C:\Windows\Temp from your web application or other way as CR uses that folder for storing files to display reports.

Tags: ,

Category: Asp.Net

Comments (13)

Trackback URL | Comments RSS Feed

  1. Thanks for the marvelous posting! I seriously enjoyed reading it, you
    are a great author.I will remember to bookmark your blog and will
    often come back at some point. I want to encourage continue your great job, have a nice weekend!

  2. I just want to mention I am newbie to weblog and absolutely loved you’re web-site. Likely I’m planning to bookmark your website . You certainly come with amazing writings. Cheers for sharing with us your webpage.

  3. Alana Lamery says:

    yeah bookmaking this wasn’t a high risk conclusion great post! .

  4. I just like the helpful info you provide on your articles. I’ll bookmark your weblog and test again right here regularly. I’m moderately sure I will be informed lots of new stuff right right here! Best of luck for the following!

  5. I just want to say I am very new to blogging and site-building and certainly liked your web site. Most likely I’m planning to bookmark your blog post . You certainly have perfect stories. Regards for revealing your webpage.

  6. Anonymous says:

    Hello, I believe your site may be having internet browser compatibility issues.
    Whenever I look at your web site in Safari, it looks
    fine however when opening in Internet Explorer, it’s got some overlapping issues. I merely wanted to give you a quick heads up! Aside from that, wonderful website!
    Look at my web blog :: how to delete cookies from computer

  7. Thank you for giving good information about Deploy Crystal Report Asp.Net Application on Server is very nice and useful..

  8. Anonymous says:

    Thanks Dude, Struggled For Days, Read You Post and was up and running in two minutes… phew!

  9. Your post is so interesting. and it is more useful and helpful for me. Thanks for share this valuable post.

  10. Anonymous says:

    Hi, thanks for the post.
    I followed the same steps but I’m getting Could not load file or assembly ‘log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=692fbea5521e1304′ or one of its dependencies. The located assembly’s manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) error. My client dont want to install anything on the server…can you please help? Thanks alot…

    Shreyash

  11. Edu Barrero says:

    VERY HELPFUL post!!! Thanks so much!!

    But i have some problems when i try yo follow yuor steps.

    1. When you talk about bin directory, do you refeer to bin directory which is generated when publish my website??

    2. When i remove assemblies in web.config, the website build fail, because dont find the namespace

    Please, help me!!

    Thanks again

  12. V.S. Saini says:

    Root folder means your website root folder.

    Application pool item for your website in IIS.

  13. Thanks for your post, very helpful. I have two questions for you:

    On A what exact location do you mean by root folder?

    On B what application pool item should that be set for? I don’t seem to have any Crystal application pool items.

    Thanks.

Leave a Reply

%d bloggers like this:
ELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy = 'nav_menu' AND t.term_id = 32 LIMIT 1 66 | 0.0002 | enabled | not cached | 897 | SELECT tr.object_id FROM wp_term_relationships AS tr INNER JOIN wp_term_taxonomy AS tt ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('nav_menu') AND tt.term_id IN ('32') ORDER BY tr.object_id ASC 67 | 0.0004 | enabled | not cached | 11135 | SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID IN (225,226,227,228,229) AND wp_posts.post_type = 'nav_menu_item' AND ((wp_posts.post_status = 'publish')) ORDER BY wp_posts.menu_order ASC 68 | 0.0003 | enabled | not cached | 2087 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (226) ORDER BY meta_id ASC 69 | 0.0002 | enabled | not cached | 2087 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (229) ORDER BY meta_id ASC 70 | 0.0003 | enabled | not cached | 2087 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (227) ORDER BY meta_id ASC 71 | 0.0003 | enabled | not cached | 2087 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (225) ORDER BY meta_id ASC 72 | 0.0003 | enabled | not cached | 2087 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (228) ORDER BY meta_id ASC 73 | 0.0004 | enabled | not cached | 4495 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ('category') AND t.term_id IN ( 4,8,9,2,3 ) ORDER BY t.name ASC 74 | 0.0001 | enabled | cached | 735 | SELECT t.term_id FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (1) ORDER BY t.name ASC 75 | 0.0002 | enabled | not cached | 529 | SELECT option_value FROM wp_options WHERE option_name = 'text_direction' LIMIT 1 76 | 0.0008 | enabled | not cached | 3834 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('post_tag') AND tr.object_id IN (1) ORDER BY t.name ASC 77 | 0.0007 | enabled | not cached | 3561 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (1) ORDER BY t.name ASC 78 | 0.0007 | enabled | not cached | 16109 | SELECT * FROM wp_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 1 ORDER BY comment_date_gmt ASC 79 | 0.0004 | enabled | not cached | 631 | SELECT p.ID FROM wp_posts AS p WHERE p.post_date < '2012-03-07 20:26:00' AND p.post_type = 'post' AND p.post_status = 'publish' ORDER BY p.post_date DESC LIMIT 1 80 | 0.0002 | enabled | not cached | 8698 | SELECT * FROM wp_posts WHERE ID = 2 LIMIT 1 81 | 0.0003 | enabled | not cached | 632 | SELECT p.ID FROM wp_posts AS p WHERE p.post_date > '2012-03-07 20:26:00' AND p.post_type = 'post' AND p.post_status = 'publish' ORDER BY p.post_date ASC LIMIT 1 82 | 0.0002 | enabled | not cached | 12152 | SELECT * FROM wp_posts WHERE ID = 339 LIMIT 1 83 | 0.0013 | enabled | not cached | 3085 | SELECT p.ID AS 'id', p.post_title AS 'title', p.post_date AS 'date', p.post_author AS 'uid', ( SUM(v.pageviews)/(IF ( DATEDIFF('2017-05-29 00:01:29', DATE_SUB('2017-05-29 00:01:29', INTERVAL 1 WEEK)) > 0, DATEDIFF('2017-05-29 00:01:29', DATE_SUB('2017-05-29 00:01:29', INTERVAL 1 WEEK)), 1) ) ) AS 'avg_views' FROM wp_popularpostssummary v LEFT JOIN wp_posts p ON v.postid = p.ID WHERE 1 = 1 AND p.post_type IN('post','page') AND v.last_viewed > DATE_SUB('2017-05-29 00:01:29', INTERVAL 1 WEEK) AND p.post_password = '' AND p.post_status = 'publish' GROUP BY v.postid ORDER BY avg_views DESC LIMIT 5; 84 | 0.0002 | enabled | not cached | 16352 | SELECT * FROM wp_posts WHERE ID = 38 LIMIT 1 85 | 0.0003 | enabled | not cached | 11284 | SELECT * FROM wp_posts WHERE ID = 17 LIMIT 1 86 | 0.0003 | enabled | not cached | 12689 | SELECT * FROM wp_posts WHERE ID = 3 LIMIT 1 87 | 0.0004 | disabled (query) | not cached | 0 | SELECT SQL_CALC_FOUND_ROWS wp_posts.ID FROM wp_posts WHERE 1=1 AND wp_posts.post_type = 'post' AND (wp_posts.post_status = 'publish') ORDER BY wp_posts.post_date DESC LIMIT 0, 5 88 | 0.0001 | disabled (query) | not cached | 0 | SELECT FOUND_ROWS() 89 | 0.0002 | enabled | not cached | 11576 | SELECT wp_posts.* FROM wp_posts WHERE ID IN (353) 90 | 0.0006 | enabled | not cached | 4227 | SELECT t.*, tt.*, tr.object_id FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category', 'post_tag', 'post_format') AND tr.object_id IN (353) ORDER BY t.name ASC 91 | 0.0003 | enabled | not cached | 3085 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (353) ORDER BY meta_id ASC 92 | 0.0019 | enabled | not cached | 7381 | SELECT DISTINCT ID, post_title, post_password, comment_ID, comment_post_ID, comment_author, comment_author_email, comment_date_gmt, comment_approved, comment_type,comment_author_url, SUBSTRING(comment_content,1,100) AS com_excerpt FROM wp_comments LEFT OUTER JOIN wp_posts ON (wp_comments.comment_post_ID = wp_posts.ID) WHERE comment_approved = '1' AND comment_type = '' AND post_password = '' ORDER BY comment_date_gmt DESC LIMIT 5 93 | 0.0002 | enabled | not cached | 10061 | SELECT * FROM wp_posts WHERE ID = 15 LIMIT 1 94 | 0.0002 | enabled | not cached | 14705 | SELECT * FROM wp_posts WHERE ID = 42 LIMIT 1 95 | 0.0006 | enabled | not cached | 2074 | SELECT YEAR(post_date) AS `year`, MONTH(post_date) AS `month`, count(ID) as posts FROM wp_posts WHERE post_type = 'post' AND post_status = 'publish' GROUP BY YEAR(post_date), MONTH(post_date) ORDER BY post_date DESC 96 | 0.0002 | enabled | cached | 4714 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ('category') ORDER BY t.name ASC 97 | 0.0006 | enabled | not cached | 8853 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy IN ('post_tag') AND tt.count > 0 ORDER BY tt.count DESC LIMIT 200 98 | 0.0003 | enabled | not cached | 3470 | SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id WHERE tt.taxonomy = 'nav_menu' AND t.term_id = 33 LIMIT 1 99 | 0.0003 | enabled | not cached | 946 | SELECT tr.object_id FROM wp_term_relationships AS tr INNER JOIN wp_term_taxonomy AS tt ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('nav_menu') AND tt.term_id IN ('33') ORDER BY tr.object_id ASC 100 | 0.0005 | enabled | not cached | 11910 | SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID IN (231,232,234,244,289,306) AND wp_posts.post_type = 'nav_menu_item' AND ((wp_posts.post_status = 'publish')) ORDER BY wp_posts.menu_order ASC 101 | 0.0003 | enabled | not cached | 2109 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (234) ORDER BY meta_id ASC 102 | 0.0002 | enabled | not cached | 2092 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (231) ORDER BY meta_id ASC 103 | 0.0002 | enabled | not cached | 2086 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (232) ORDER BY meta_id ASC 104 | 0.0002 | enabled | not cached | 2086 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (289) ORDER BY meta_id ASC 105 | 0.0002 | enabled | not cached | 2086 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (244) ORDER BY meta_id ASC 106 | 0.0002 | enabled | not cached | 2086 | SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (306) ORDER BY meta_id ASC 107 | 0.0005 | enabled | not cached | 26613 | SELECT wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID IN (207,209,279,239,301) AND wp_posts.post_type = 'page' AND ((wp_posts.post_status = 'publish')) ORDER BY wp_posts.post_date DESC 108 | 0.0001 | enabled | cached | 735 | SELECT t.term_id FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (1) ORDER BY t.name ASC 109 | 0.0001 | enabled | cached | 559 | select meta_key from wp_postmeta where meta_key like '_wp_page_template' and meta_value like 'page-youtube.php' 110 | 0.0001 | enabled | cached | 625 | select meta_key from wp_postmeta where meta_key like '_wp_page_template' and meta_value like 'page-portfolio.php' 111 | 0.0001 | enabled | cached | 559 | select meta_key from wp_postmeta where meta_key like '_wp_page_template' and meta_value like 'page-youtube.php' 112 | 0.0001 | enabled | cached | 625 | select meta_key from wp_postmeta where meta_key like '_wp_page_template' and meta_value like 'page-portfolio.php' -->