Here is the error message -- and below that is the connection string snippet to the sample DB from web.config and also all of Default.aspx (no .cs file - just ajax in the source) -- I'm using sql server 2008 RS (for desktop) and using VS2008 C# for the app
-- how do I fix this error?
The sample tutorial I am following is at
http://aspnet.4guysfromrolla.com/articles/062106-1.aspx, and the web page is supposed to look like this (there is only one table in the sample DB -- Employees) -- how can I fix my sample so that it runs like this?
I fixed the problem. The main problem is that I lack self confidence and thus had to ask fellow programmers to help me rule out possible issues. Then I discovered that I was missing my table Adapter, and then the ObjectDataSource thing needed to be replaced.
So I added the Table DataAdapter and replaced the ObjectDataSource control. Now my sample works.
Thank you for replies to help me rule out the other issues.
Rich dvc
Member
91 Points
212 Posts
Error with my data source for an Ajax Demo app - how to fix? (VS2008)
Nov 07, 2012 09:18 PM|LINK
Here is the error message -- and below that is the connection string snippet to the sample DB from web.config and also all of Default.aspx (no .cs file - just ajax in the source) -- I'm using sql server 2008 RS (for desktop) and using VS2008 C# for the app -- how do I fix this error?
--web.config
...
<connectionStrings>
<add name="DatabaseConnectionString" connectionString="Data Source=COMP10\SQL2008R2;Initial Catalog=AtlasAjaxDem;Integrated Security=True;" providerName="System.Data.SqlClient" />
</connectionStrings>
...
-------------------------------------
--Default.aspx
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<atlas:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true"/>
<atlas:UpdatePanel runat="server" ID="UpdatePanel1" Mode="Conditional">
<ContentTemplate>
<asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="True"
AutoGenerateColumns="False" DataKeyNames="EmployeeId" DataSourceID="ObjectDataSource1">
<Columns>
<asp:CommandField ShowEditButton="True" />
<asp:BoundField DataField="EmployeeId" HeaderText="EmployeeId" InsertVisible="False"
ReadOnly="True" SortExpression="EmployeeId" />
<asp:BoundField DataField="FirstName" HeaderText="FirstName" SortExpression="FirstName" />
<asp:BoundField DataField="LastName" HeaderText="LastName" SortExpression="LastName" />
<asp:BoundField DataField="Department" HeaderText="Department" SortExpression="Department" />
</Columns>
</asp:GridView>
<asp:ObjectDataSource ID="ObjectDataSource1" runat="server" DeleteMethod="Delete"
InsertMethod="Insert" OldValuesParameterFormatString="original_{0}" SelectMethod="GetData"
TypeName="DataSet1TableAdapters.EmployeesTableAdapter" UpdateMethod="Update">
<DeleteParameters>
<asp:Parameter Name="Original_EmployeeId" Type="Int16" />
</DeleteParameters>
<UpdateParameters>
<asp:Parameter Name="FirstName" Type="String" />
<asp:Parameter Name="LastName" Type="String" />
<asp:Parameter Name="Department" Type="String" />
<asp:Parameter Name="Original_EmployeeId" Type="Int16" />
</UpdateParameters>
<InsertParameters>
<asp:Parameter Name="FirstName" Type="String" />
<asp:Parameter Name="LastName" Type="String" />
<asp:Parameter Name="Department" Type="String" />
</InsertParameters>
</asp:ObjectDataSource>
</ContentTemplate>
</atlas:UpdatePanel>
</form>
<script type="text/xml-script">
<page xmlns:script="http://schemas.microsoft.com/xml-script/2005">
<references>
</references>
<components>
</components>
</page>
</script>
</body>
</html>
THANKS
Rich dvc
Member
91 Points
212 Posts
Re: Error with my data source for an Ajax Demo app - how to fix? (VS2008)
Nov 07, 2012 09:53 PM|LINK
The sample tutorial I am following is at http://aspnet.4guysfromrolla.com/articles/062106-1.aspx, and the web page is supposed to look like this (there is only one table in the sample DB -- Employees) -- how can I fix my sample so that it runs like this?
chetan.sarod...
All-Star
66569 Points
11265 Posts
Re: Error with my data source for an Ajax Demo app - how to fix? (VS2008)
Nov 08, 2012 03:07 AM|LINK
Refer this
http://insomniacgeek.com/how-to-fix-the-the-type-specified-in-the-typename-property-of-objectdatasource-could-not-be-found-error-in-a-sharepoint-custom-solution/
http://stackoverflow.com/questions/4406267/need-help-with-error-the-type-specified-in-the-typename-property-of-objectdata
http://forums.asp.net/t/1806881.aspx/1
http://social.msdn.microsoft.com/Forums/en/csharpgeneral/thread/25b14490-d542-40a6-b3c5-b37189e09df0
Senior Software Engineer,
Approva Systems Pvt Ltd, Pune, India.
Rich dvc
Member
91 Points
212 Posts
Re: Error with my data source for an Ajax Demo app - how to fix? (VS2008)
Nov 08, 2012 07:52 PM|LINK
I fixed the problem. The main problem is that I lack self confidence and thus had to ask fellow programmers to help me rule out possible issues. Then I discovered that I was missing my table Adapter, and then the ObjectDataSource thing needed to be replaced. So I added the Table DataAdapter and replaced the ObjectDataSource control. Now my sample works.
Thank you for replies to help me rule out the other issues.