.net Datagrid question, Stop add new row when editing

Posted on 2004-11-04
Last Modified: 2010-04-24

very quick question, the answer in fact is problably only one line but i will be damned if i can find it. I have a datagrid which has a button to add new data from a custom dialog. I allow editing in the datagrid itself, what i dont want is to allow users to be able to add a new row from the automatically generated new row element at the bottom of the datagrid.

The reason for this is that this data contrains filenames which i want some level of validation over.


Question by:james-ct16
    LVL 25

    Expert Comment

    Use a dataview as your datasource for the grid and set dv.allownew = false
    LVL 25

    Accepted Solution

    If you use a dataview you can idividualy set the following options

    LVL 10

    Author Comment

    thankyou for your help


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
    The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (…
    This video discusses moving either the default database or any database to a new volume.
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    761 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    8 Experts available now in Live!

    Get 1:1 Help Now