VISUAL STUDIO 2022 REPORT PROJECT ADDING EXTERNAL LIBRARIES PATH

Sushil Agarwal 406 Reputation points
2023-12-23T03:00:08.09+00:00

i am trying to add my rdl files to new report project .

the report has got calls to external assemblies for priting barcode, q.r.code

on running the report i am getting error that assmbles can not be found

i have copies them to bin\debug folder of project. but still i am getting erro.

where to copy these files so that report can be run

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,888 questions
SQL Server Reporting Services
SQL Server Reporting Services
A SQL Server technology that supports the creation, management, and delivery of both traditional, paper-oriented reports and interactive, web-based reports.
2,916 questions
0 comments No comments
{count} votes

5 answers

Sort by: Most helpful
  1. Bhavesh Sharma 0 Reputation points
    2023-12-23T03:24:32.78+00:00

    Make sure you've added references to the external assemblies within your report project. Additionally, consider placing the required assemblies in the same directory as your report file (.rdl) or in a common location referenced by your project. This might be the "bin\debug" folder, but sometimes it's necessary to place them in the project's root directory or a dedicated "Lib" folder.

    Verify that your project's build settings are set to copy the referenced assemblies to the output directory. Right-click on the reference in Solution Explorer, go to "Properties," and set "Copy Local" to true.

    If the issue persists, manually copy the assemblies to the output directory (where your executable or report file is) after building the project. This ensures that the required assemblies are available during runtime.

    Remember to restart your development environment and clear any existing output files before running the project again. This should help resolve assembly-related issues.


  2. AniyaTang-MSFT 12,446 Reputation points Microsoft Vendor
    2023-12-25T06:53:04.95+00:00

    Hi @Sushil Agarwal

    This document introduces the reference to the assembly set in the Report Designer: Custom code and assembly references in expressions in a paginated report in Report Designer (SSRS). Maybe you can check whether your steps are correct.

    You can also provide more detailed error messages and error page screenshots to facilitate us to solve the problem better for you.

    If the answer is helpful, please click Accept Answer and Up-Vote for the same. If you have any questions, please feel free to let me know.

    Best regards,

    Aniya


  3. AniyaTang-MSFT 12,446 Reputation points Microsoft Vendor
    2023-12-27T05:37:09.7533333+00:00

    Hi @Sushil Agarwal

    Here are some examples of using QR Code in SSRS reports, maybe you can use them as a reference.

    https://barcodewiz.com/qr-code-fonts/ssrs/qr-code-barcodes-with-sql-server-reporting-services-ssrs

    https://www.sqlservercentral.com/articles/generate-qr-code-barcodes-in-an-ssrs-report-with-the-qrcoder-library

    If the answer is helpful, please click Accept Answer and Up-Vote for the same. If you have any questions, please feel free to let me know.

    Best regards,

    Aniya


  4. Sushil Agarwal 406 Reputation points
    2023-12-29T04:46:37.8633333+00:00

    Thanks for your guidance and valuable time.

    my question is where to copy external dlls which are used in ssrs references, for example to get barcode/Q.R. printed in ssrs. that process for earlier vversions of visual sttudio is known to me. only vs2022 the report project is not fiinding them when i try to preview report from vs2022 preview option. other wise that report in application is running well , the required libraries in bin directory of application works well.

    just to remind all here that diffrent locations fo copy dlls were as under

    echo Barcode.dll File Copied Paths

    C:\Program Files\Microsoft SQL Server\MSRS13.MSSQLSERVER\Reporting Services\ReportServer\bin

    C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\Microsoft\VisualStudio\v15.0\SSDT

    C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin

    C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\PrivateAssemblies

    C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\CommonExtensions\Microsoft\SSDTRS

    C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\PrivateAssemblies

    C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\PrivateAssemblies

    C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\PrivateAssemblies

    C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\PrivateAssemblies

    C:\Program Files (x86)\MSBuild\14.0\Bin

    copy .dll in following folder only applicable for vs2017/vs2019 both

    C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\CommonExtensions\Microsoft\SSRS

    BarcodeLib45.dll

    Gma.QrCodeNet.Encoding.dll

    vs2019 community

    C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\CommonExtensions\Microsoft\SSRS

    for ssrs 2017 and above

    https://docs.microsoft.com/en-us/sql/reporting-services/custom-assemblies/deploying-a-custom-assembly?view=sql-server-ver15

    %ProgramFiles%\Microsoft SQL Server Reporting Services\SSRS\ReportServer\bin

    for report builder put assemlies to

    C:\Program Files (x86)\Microsoft Report Builder

    What is the path for Vs2022


  5. Sushil Agarwal 406 Reputation points
    2024-08-09T17:34:37.72+00:00

    Please try

    %ProgramFiles%\Microsoft SQL Server Reporting Services\SSRS\ReportServer\bin

    as per my understanding from following microsoft url

    https://learn.microsoft.com/en-us/sql/reporting-services/custom-assemblies/deploying-a-custom-assembly?view=sql-server-ver15

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.