locked
DataSet not recognized as buesiness object by ObjectDataSource RRS feed

  • Question

  • User-1133392269 posted

    I have an ObjectDataSource in Visual Studio 2008.  I have a DataSet defined with a TableAdapter.  However, when I go to select the Table Adapter to use in the ObjectDataSource, nothing shows up.  I double checked that the DataSet is in fact in the App_Code folder.  I do not know what else to try.  The following code is the ASP code for that ObjectDataSource:

     

    <

     

    asp:ObjectDataSource ID="ObjectDataSource1" runat="server" DeleteMethod="Delete" InsertMethod="Insert" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" TypeName="NewDataSetTableAdapters.PlansTableAdapter" UpdateMethod="Update" >

    <DeleteParameters>

     

    <asp:Parameter Name="Original_ID" Type="Int32" />

     

    </DeleteParameters>

    <UpdateParameters>

    <asp:Parameter Name="DO" Type="String" />

     

    <asp:Parameter Name="Task" Type="String" />

     

    <asp:Parameter Name="PDesc" Type="String" />

     

    <asp:Parameter Name="TTitle" Type="String" />

     

    <asp:Parameter Name="Employee" Type="String" />

     

    <asp:Parameter Name="Employee_Name" Type="String" />

     

    <asp:Parameter Name="Company" Type="String" />

     

    <asp:Parameter Name="Hours" Type="Double" />

     

    <asp:Parameter Name="Period" Type="String" />

     

    <asp:Parameter Name="Year" Type="String" />

     

    <asp:Parameter Name="Acct" Type="String" />

     

    <asp:Parameter Name="Revision" Type="String" />

     

    <asp:Parameter Name="Rate" Type="Double" />

     

    <asp:Parameter Name="Skill" Type="String" />

     

    <asp:Parameter Name="Raise" Type="Double" />

     

    <asp:Parameter Name="Amount" Type="Double" />

     

    <asp:Parameter Name="Support" Type="Double" />

     

    <asp:Parameter Name="Fringe" Type="Double" />

     

    <asp:Parameter Name="Overhead" Type="Double" />

     

    <asp:Parameter Name="ODC" Type="Double" />

     

    <asp:Parameter Name="Facility" Type="Double" />

     

    <asp:Parameter Name="TotalCostInput" Type="Double" />

     

    <asp:Parameter Name="GA" Type="Double" />

     

    <asp:Parameter Name="Subtotal" Type="Double" />

     

    <asp:Parameter Name="Fee" Type="Double" />

     

    <asp:Parameter Name="TotalCost" Type="Double" />

     

    <asp:Parameter Name="Code" Type="String" />

     

    <asp:Parameter Name="CodeB" Type="String" />

     

    <asp:Parameter Name="PlanVer" Type="String" />

     

    <asp:Parameter Name="Status" Type="Boolean" />

     

    <asp:Parameter Name="ValueLevel" Type="String" />

     

    <asp:Parameter Name="Original_ID" Type="Int32" />

     

    </UpdateParameters>

     

    <SelectParameters>

     

     

    <asp:ControlParameter ControlID="ProjectDropDownList" Name="Project" PropertyName="SelectedValue" Type="String" />

     

     

    <asp:ControlParameter ControlID="VersionDropDownList" Name="Version" PropertyName="SelectedValue" Type="String" />

     

    </SelectParameters>

     

    <InsertParameters>

     

    <asp:Parameter Name="DO" Type="String" />

     

    <asp:Parameter Name="Task" Type="String" />

     

    <asp:Parameter Name="PDesc" Type="String" />

     

    <asp:Parameter Name="TTitle" Type="String" />

     

    <asp:Parameter Name="Employee" Type="String" />

     

    <asp:Parameter Name="Employee_Name" Type="String" />

     

    <asp:Parameter Name="Company" Type="String" />

     

    <asp:Parameter Name="Hours" Type="Double" />

     

    <asp:Parameter Name="Period" Type="String" />

     

    <asp:Parameter Name="Year" Type="String" />

     

    <asp:Parameter Name="Acct" Type="String" />

     

    <asp:Parameter Name="Revision" Type="String" />

     

    <asp:Parameter Name="Rate" Type="Double" />

     

    <asp:Parameter Name="Skill" Type="String" />

     

    <asp:Parameter Name="Raise" Type="Double" />

     

    <asp:Parameter Name="Amount" Type="Double" />

     

    <asp:Parameter Name="Support" Type="Double" />

     

    <asp:Parameter Name="Fringe" Type="Double" />

     

    <asp:Parameter Name="Overhead" Type="Double" />

     

    <asp:Parameter Name="ODC" Type="Double" />

     

    <asp:Parameter Name="Facility" Type="Double" />

     

    <asp:Parameter Name="TotalCostInput" Type="Double" />

     

    <asp:Parameter Name="GA" Type="Double" />

     

    <asp:Parameter Name="Subtotal" Type="Double" />

     

    <asp:Parameter Name="Fee" Type="Double" />

     

    <asp:Parameter Name="TotalCost" Type="Double" />

     

    <asp:Parameter Name="Code" Type="String" />

     

    <asp:Parameter Name="CodeB" Type="String" />

     

    <asp:Parameter Name="PlanVer" Type="String" />

     

    <asp:Parameter Name="Status" Type="Boolean" />

     

    <asp:Parameter Name="ValueLevel" Type="String" />

     

    </InsertParameters>

     

    </asp:ObjectDataSource>

     

    Monday, November 15, 2010 1:02 PM

Answers

  • User470413944 posted

    HI,

    The codes looks fine to me. You can check in DataSet if the adapters can get data correctly, and the connect string is right.

    I'm looking forward for your reply. 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 18, 2010 5:31 AM

All replies

  • User470413944 posted

    HI,

    The codes looks fine to me. You can check in DataSet if the adapters can get data correctly, and the connect string is right.

    I'm looking forward for your reply. 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 18, 2010 5:31 AM
  • User1160042863 posted

    I found out that after creating an tabladapter you must build the project for objects to be visiable to your datasource.  Hope this helps.

    Thursday, December 6, 2012 12:14 PM