none
Excel Red Tick Mark for invalid data RRS feed

  • Question

  • I have an Excel VSTO document level add in. Before pushing changes in the spreadsheet to the database my customer wants data validation to occur. What they want is for all invalid cells to have a "red tick mark" in the cell. I can easily find the cells that need to be marked, but I have no idea what a red tick mark looks like. Anyone know what this might mean? Or is there a standard way of indicating invalid data in a cell?
    Wednesday, February 20, 2013 7:16 PM

All replies

  • Hi Jeffki,

    Thank you for posting in the MSDN Forum.

    According to your description, I think you can try to fill color to those invalid cells.

    Hope it helps.

    Best regards,


    Quist Zhang [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Thursday, February 21, 2013 9:41 AM
    Moderator
  • I don't want to lose the alternating clue/white fill color on every other row. I tried using the border with the code below but it applied it to all the cells in the sheet instead of the cell that are data bound. 1. Does data binding have a style that over rides what I set in the cell? 2. What is wrong with the code below that it sets the right border of every cell on the sheet?

                               

    this.Application.ExtendList = false;

    Cells[r, ColumnNameColumn].style.Borders[(Excel.

    XlBordersIndex)Excel.Constants.xlRight].LineStyle = Excel.XlLineStyle.xlContinuous;

    Cells[r, ColumnNameColumn].style.Borders[(Excel.

    XlBordersIndex)Excel.Constants.xlRight].Color = -16776961;

    Cells[r, ColumnNameColumn].style.Borders[(Excel.

    XlBordersIndex)Excel.Constants.xlRight].Weight = Excel.XlBorderWeight.xlThick;

    Friday, February 22, 2013 11:16 PM