EDM problem

This is a discussion on EDM problem within the C# Programming forums, part of the General Programming Boards category; Hi! After creating an app with EDM database model with several tables (SQL db), i added a new column ("SoldStuff") ...

  1. #1
    Android
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    374

    EDM problem

    Hi!

    After creating an app with EDM database model with several tables (SQL db), i added a new column ("SoldStuff") to a table. Then i went "Update model from database" to update the variables bound to the tables, so the newly added columns can be accessed through the code. But when i run the app, i get the runtime exception "Invalid column name 'SoldStuff'" when i try to bind the updated table with a DataGridview control:

    Code:
    private CoffeeShopDatabaseEntities cse = new CoffeeShopDatabaseEntities();
        
    public SalesReport()
    {
    InitializeComponent();
    dataGridView1.DataSource = cse.TblTransactions; //runtime exception: "Invalid column name 'SoldStuff'"
    }
    How to fix this please?

    Thanks.
    Last edited by geek@02; 06-22-2012 at 07:45 PM.
    Some useless programs i've wrote : slprogrammersheaven
    Youtube: http://www.youtube.com/user/geekyzine
    My amature IT Blog: http://everything-geeky.blogspot.com/
    My Flash games: http://flashweed.blogspot.com/

    (and, sorry for my amature english)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. sleep() function problem or logic problem?
    By FernandoBasso in forum C Programming
    Replies: 7
    Last Post: 11-16-2011, 04:50 PM
  2. Replies: 4
    Last Post: 10-16-2008, 07:30 PM
  3. sturct/pointer problem, and fscanf problem
    By hiphop4reel in forum C Programming
    Replies: 6
    Last Post: 07-28-2008, 09:40 AM
  4. Visual Studio Linker problem or my problem?
    By OOPboredom in forum C Programming
    Replies: 2
    Last Post: 04-13-2004, 12:32 AM
  5. syntax linked list problem & struct problem
    By beely in forum C Programming
    Replies: 5
    Last Post: 11-11-2002, 08:14 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21