Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • MK 429 posts 906 karma points
    Jun 04, 2012 @ 12:04
    MK
    1

    Data Type Grid - Checking if not empty

    Hi there,
    I'm using the uComponent grid and would like to check if its not empty.
    I can check if the count is bigger than 0 but when there are no values it will return and empty string.
    I cant check for empty string cos when there are values it will express an DynamicXML structure.
    Any Idea?
    Cheers
    mkariti 
  • Douglas Ludlow 210 posts 366 karma points
    Jun 04, 2012 @ 17:08
    Douglas Ludlow
    0

    You would check the type of the property as well as the count:

    if (Model.dataTypeGrid.GetType() == typeof(DynamicXml) && Model.dataTypeGrid.Count() > 0)
    {
        //If not empty...
    }
  • MK 429 posts 906 karma points
    Jun 05, 2012 @ 08:30
    MK
    0

    Work like a charm!

    Cheers

Please Sign in or register to post replies

Write your reply to:

Draft