database permissions lost...

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Wade

    database permissions lost...

    Using Visual Basic 2005 Express, I have a form with a DataGridView control
    on it. The DataGridView Dataset is a SQL Express 2005 db (1 table, 5
    fields). If I Start debugging (F5 key) the form builds, and the data is
    shown in the DataGridView just fine. But if I run Debug, and the build
    fails or if the form crashes for some reason, I cannot access the info in
    the SQL Express 2005 db with future Debugs. The point of failure is at this
    code:
    Me.TblFileTrack ingTableAdapter .Fill(Me.FileTr ackingDataSet.t blFileTracking)

    ....in the Form1_Load sub (this usually fills the DataGridView with all
    records in the database).

    The error message is:
    {"Request for the permission of type
    'System.Data.Sq lClient.SqlClie ntPermission, System.Data, Version=2.0.0.0 ,
    Culture=neutral , PublicKeyToken= b77a5c561934e08 9' failed."}

    If I right click the table name in the Data Sources window and select
    Preview Data..., all records in the SQL Express 2005 db are diplayed, so I'm
    not locked out there. The only failure is when the form tries to open - in
    Debug mode or Release.

    Is there anyway to get the permissions back without having to create a new
    Project, Form, and DataGridView (starting from scratch)? So far this has
    been my only solution.

    Thanks in advance.



Working...