SSRS Export to Excel - not show green triagles

Spunny 326 Reputation points
2022-10-28T16:27:06.083+00:00

Hi, in our automated process, we are running ssrs web service to run a report and generate excel file. When excel file is opened, all number or decimal columns are showing with green triangles at the corners. In SSRS report I tried to
textbox - textbox properties - number - custom and added below code
=iif(instr(cstr(Fields!fieldname.Value),".")=0,Cint(Fields!fieldname.Value),Fields!fieldname.Value)

still I am seeing green triangles. How can I avoid it.

Thanks,

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,949 questions
0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Joyzhao-MSFT 15,596 Reputation points
    2022-10-31T02:07:18.463+00:00

    Hi @Spunny ,
    If the data contained in a cell has an error as far as Excel is concerned, and background error checking is switched on, then a small green triangle will be shown in the left hand top corner of a cell. If you were to click in the cell, a drop down list of solutions to the error will be offered. On some occasions, you may not want to amend the data in your cell, but you may want to hide the green triangle, thus ignoring the error. If you just want to ignore the little green triangles, check out: How to Get Rid of the Green Triangle in Excel.
    Or you should check that the expressions in the report are correct, for example, to see if division with a denominator of 0 is handled properly, and if aggregate functions such as the sum function are used correctly.
    Best Regards,
    Joy


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  2. AniyaTang-MSFT 12,446 Reputation points Microsoft Vendor
    2022-10-31T03:14:06.827+00:00

    Hi @Spunny
    The appearance of a green triangle in Excel indicates that the cell is a number in text format. If you need subsequent number operations, then you need to select Convert to Number in the pop-up "!" button after selecting the cell. If no computation is required, then you can choose to ignore errors, or click File-Options-Formulas and deselect "Enable background error checking".
    Best regards,
    Aniya

    0 comments No comments

  3. Olaf Helper 45,286 Reputation points
    2022-11-01T07:09:46.53+00:00

    Set the "Format" property to a numeric format like "N0" = numeric with 0 decimal places.

    0 comments No comments

  4. Daniel Read 0 Reputation points
    2023-11-16T20:46:00.8566667+00:00

    Key solution for me today was to make sure the query is returning a numeric data type, rather than nvarchar!

    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.