473,376 Members | 1,216 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,376 software developers and data experts.

An OleDbParameter with ParameterName '@ID' is not contained by thisOleDbParameterCollection problem

DC
The Code

<%@ import namespace="System" %>
<%@ import namespace="System.Web" %>
<%@ import namespace="System.Web.UI" %>
<%@ import namespace="System.Web.UI.HtmlControls" %>
<%@ import namespace="System.Web.UI.WebControls" %>
<%@ import namespace="System.Data" %>
<%@ import namespace="System.Data.OleDb" %>

<html>
<head>

<title>Meetings Admin Page</title>

<meta NAME="keywords" CONTENT="Meetings">

<meta NAME="description" CONTENT="Meetings Admin Page">

<link REL="ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">
<link REL="SHORTCUT ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">

<meta name="MSSmartTagsPreventParsing" content="TRUE">

<script language="C#" runat="server">

public void Page_Load(object sender, System.EventArgs e)
{
if (Page.IsPostBack != true)
{

}
}

void MeetingsGridView_OnSelectedIndexChanged(Object sender, EventArgs e)
{
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue
= MeetingsGridView.SelectedValue.ToString();
MeetingsFormView.DataBind();
}
void MeetingsFormView_ItemUpdated(Object sender,
FormViewUpdatedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsFormView_ItemDeleted(Object sender,
FormViewDeletedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsDetailsAccessDataSource_OnInserted(Object sender,
SqlDataSourceStatusEventArgs e)
{

System.Data.Common.DbCommand command = e.Command;

MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();

Response.Write(ID);

MeetingsGridView.DataBind();
MeetingsFormView.DataBind();

}
</script>
</head>

<body bgcolor=#FFFFFF>

<!-- Start of page header section -->

<!-- Stylesheet Location -->

<link rel="stylesheet" type="text/css" href="/scripts/includes/style.css">

<!-- Page Header info goes here -->

<BR>

<center>

<H3>Seminars Admin Page</H3>

<form RunAt="server">

<table cellspacing="10">

<tr>

<td valign="top">
<asp:FormView ID="MeetingsFormView"
DataSourceID="MeetingsDetailsAccessDataSource"
DataKeyNames="ID"
Gridlines="Both"
OnItemUpdated="MeetingsFormView_ItemUpdated"
OnItemDeleted="MeetingsFormView_ItemDeleted"
RunAt="server">

<HeaderStyle backcolor="Navy"
forecolor="White"/>

<RowStyle backcolor="White"/>

<EditRowStyle backcolor="LightCyan"/>

<ItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%#
Eval("ID") %></td></tr>
<tr><td align=right><B>Seminar Title:</B></td>
<td><%# Eval("SeminarTitle") %></td></tr>
<tr><td align=right><B>Speaker:</B></td <td><%#
Eval("Speaker") %></td></tr>
<tr><td align=right><B>Speaker Email:</B></td>
<td><%# Eval("SpeakerEmail") %></td></tr>
<tr><td align=right><B>Speaker
Institution:</B></td <td><%# Eval("SpeakerInstitution") %></td></tr>
<tr><td align=right><B>Seminar Date:</B></td>
<td><%# Eval("SeminarDate") %></td></tr>
<tr><td align=right><B>Seminar Time:</B></td>
<td><%# Eval("SeminarTime") %></td></tr>
<tr><td align=right><B>Seminar Location:</B></td>
<td><%# Eval("SeminarLocation") %></td></tr>
<tr><td align=right><B>Seminar Details:</B></td>
<td><%# Eval("SeminarDetails") %></td></tr>
<tr><td align=right><B>Seminar Host:</B></td>
<td><%# Eval("SeminarHost") %></td></tr>
<tr><td align=right><B>Seminar Host Email:</B></td>
<td><%# Eval("SeminarHostEmail") %></td></tr>
<tr><td align=right><B>Seminar Type:</B></td>
<td><%# Eval("SeminarType") %></td></tr>
<tr><td align=right><B>Organisation Notes:</B></td>
<td><%# Eval("OrganisationNotes") %></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="EditButton"
Text="Edit"
CommandName="Edit"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="NewButton"
Text="New"
CommandName="New"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="DeleteButton"
Text="Delete"
CommandName="Delete"
RunAt="server"/>
</td>
</tr>
</table>
</ItemTemplate>

<EditItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%#
Eval("ID") %></td></tr>

<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="EditSeminarTitleTextBox"
Text='<%# Bind("SeminarTitle")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="EditSpeakerTextBox"
Text='<%# Bind("Speaker") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="EditSpeakerEmailTextBox"
Text='<%# Bind("SpeakerEmail")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="EditSpeakerInstitutionTextBox"
Text='<%#
Bind("SpeakerInstitution") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="EditSeminarDateTextBox"
Text='<%# Bind("SeminarDate") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="EditSeminarTimeTextBox"
Text='<%# Bind("SeminarTime") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="EditSeminarLocationTextBox"
Text='<%#
Bind("SeminarLocation") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="EditSeminarDetailsTextBox"
Text='<%#
Bind("SeminarDetails") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="EditSeminarHostTextBox"
Text='<%# Bind("SeminarHost") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox ID="EditSeminarHostEmailTextBox"
Text='<%#
Bind("SeminarHostEmail") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="EditSeminarTypeTextBox"
Text='<%# Bind("SeminarType") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox ID="EditOrganisationNotesTextBox"
Text='<%#
Bind("OrganisationNotes") %>'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="UpdateButton"
Text="Update"
CommandName="Update"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelUpdateButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</EditItemTemplate>

<InsertItemTemplate>
<table>
<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="InsertSeminarTitleTextBox"
Text='Seminar Title'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="InsertSpeakerTextBox"
Text='Speaker Name'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="InsertSpeakerEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="InsertSpeakerInstitutionTextBox"
Text='Reading Meteorlogy Dept'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="InsertSeminarDateTextBox"
Text='1/1/2006'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="InsertSeminarTimeTextBox"
Text='12.00'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="InsertSeminarLocationTextBox"
Text='Sutcliffe Lecture
Theatre (GU01)'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="InsertSeminarDetailsTextBox"
Text='Add some Seminar Details'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="InsertSeminarHostTextBox"
Text='Seminar Host'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox
ID="InsertSeminarHostEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="InsertSeminarTypeTextBox"
Text='Lunchtime Seminar'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox
ID="InsertOrganisationNotesTextBox"
Text='Organisation Notes'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="InsertButton"
Text="Insert"
CommandName="Insert"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelInsertButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</InsertItemTemplate>

</asp:FormView>

</td>
</tr>
<tr>
<td>
<asp:GridView ID="MeetingsGridView"
DataSourceID="MeetingsAccessDataSource"
AutoGenerateColumns="false"
DataKeyNames="ID"

OnSelectedIndexChanged="MeetingsGridView_OnSelecte dIndexChanged"
RunAt="Server">

<HeaderStyle backcolor="cornsilk"
forecolor="Black" />

<Columns>

<asp:ButtonField Text="Show Details."
HeaderText="Show<BR>Details"
CommandName="Select"/>

<asp:BoundField DataField="ID" HeaderText="Item ID"/>
<asp:BoundField DataField="SeminarTitle"
HeaderText="Seminar Title"/>
<asp:BoundField DataField="Speaker"
HeaderText="Speaker"/>
<asp:BoundField DataField="SpeakerEmail" HeaderText="Speaker Email"/>
<asp:BoundField DataField="SpeakerInstitution" HeaderText="Speaker
Institution"/>
<asp:BoundField DataField="SeminarDate" HeaderText="Seminar Date"/>
<asp:BoundField DataField="SeminarTime" HeaderText="Seminar
Time"/>
<asp:BoundField DataField="SeminarLocation"
HeaderText="Seminar Location"/>

</Columns>

</asp:GridView>

</td>

</tr>

</table>

<asp:AccessDataSource
id="MeetingsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList">

</asp:AccessDataSource>
<asp:AccessDataSource
id="MeetingsDetailsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList WHERE ID=@ID"

InsertCommand="INSERT INTO SeminarList
(ID,SeminarTitle,Speaker,SpeakerEmail,SpeakerInsti tution,SeminarDate,SeminarTime,SeminarLocation,Sem inarDetails,SeminarHost,SeminarHostEmail,SeminarTy pe,OrganisationNotes)
VALUES (@ID,
@SeminarTitle,@Speaker,@SpeakerEmail,@SpeakerInsti tution,@SeminarDate,@SeminarTime,@SeminarLocation, @SeminarDetails,@SeminarHost,@SeminarHostEmail,@Se minarType,@OrganisationNotes)"

UpdateCommand="UPDATE SeminarList SET
SeminarTitle=@SeminarTitle,Speaker=@Speaker,Speake rEmail=@SpeakerEmail,SpeakerInstitution=@SpeakerIn stitution,SeminarDate=@SeminarDate,SeminarTime=@Se minarTime,SeminarLocation=@SeminarLocation,Seminar Details=@SeminarDetails,SeminarHost=@SeminarHost,S eminarHostEmail=@SeminarHostEmail,SeminarType=@Sem inarType,OrganisationNotes=@OrganisationNotes
WHERE ID=@ID"

DeleteCommand="DELETE FROM SeminarList WHERE ID=@ID"

OnInserted="MeetingsDetailsAccessDataSource_OnInse rted">
<SelectParameters>
<asp:QueryStringParameter Name="ID" Type="Int32"
QueryStringField="ID" />

</SelectParameters>

<InsertParameters>
<asp:Parameter Name="SeminarTitle" Direction="Output" Type="String"
DefaultValue="Seminar Title" />
<asp:Parameter Name="Speaker" Direction="Output" Type="String"
DefaultValue="Speaker" />
<asp:Parameter Name="SpeakerEmail" Direction="Output" Type="String"
DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SpeakerInstitution" Direction="Output"
Type="String" DefaultValue="Speaker Institution" />
<asp:Parameter Name="SeminarDate" Direction="Output"
Type="DateTime" DefaultValue="1/1/2006" />
<asp:Parameter Name="SeminarTime" Direction="Output" Type="String"
DefaultValue="12.00" />
<asp:Parameter Name="SeminarLocation" Direction="Output"
Type="String" DefaultValue="Seminar Location" />
<asp:Parameter Name="SeminarDetails" Direction="Output"
Type="String" DefaultValue="Seminar Details" />
<asp:Parameter Name="SeminarHost" Direction="Output" Type="String"
DefaultValue="Seminar Host" />
<asp:Parameter Name="SeminarHostEmail" Direction="Output"
Type="String" DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SeminarType" Direction="Output" Type="String"
DefaultValue="Lunchtime Seminar" />
<asp:Parameter Name="OrganisationNotes" Direction="Output"
Type="String" DefaultValue="Organisation Notes" />
</InsertParameters>

</asp:AccessDataSource>

</form>

</center>

</body>

</html><%@ import namespace="System" %>
<%@ import namespace="System.Web" %>
<%@ import namespace="System.Web.UI" %>
<%@ import namespace="System.Web.UI.HtmlControls" %>
<%@ import namespace="System.Web.UI.WebControls" %>
<%@ import namespace="System.Data" %>
<%@ import namespace="System.Data.OleDb" %>

<html>
<head>

<title>Meteorology Department Meetings Admin Page</title>

<meta NAME="keywords" CONTENT="meteorology dept, Meetings">

<meta NAME="description" CONTENT="Meteorology Department Meetings Admin
Page">
<meta NAME="htdig-email" CONTENT="we****@met.rdg.ac.uk">

<META HTTP-EQUIV=REFRESH CONTENT=1800>

<link REL="ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">
<link REL="SHORTCUT ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">

<meta name="MSSmartTagsPreventParsing" content="TRUE">

<script language="C#" runat="server">

public void Page_Load(object sender, System.EventArgs e)
{
if (Page.IsPostBack != true)
{

}
}

void MeetingsGridView_OnSelectedIndexChanged(Object sender, EventArgs e)
{
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue
= MeetingsGridView.SelectedValue.ToString();
MeetingsFormView.DataBind();
}
void MeetingsFormView_ItemUpdated(Object sender,
FormViewUpdatedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsFormView_ItemDeleted(Object sender,
FormViewDeletedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsDetailsAccessDataSource_OnInserted(Object sender,
SqlDataSourceStatusEventArgs e)
{

System.Data.Common.DbCommand command = e.Command;

MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();

Response.Write(ID);

MeetingsGridView.DataBind();
MeetingsFormView.DataBind();

}
</script>
</head>

<body bgcolor=#FFFFFF>

<!-- Start of page header section -->

<!-- Stylesheet Location -->

<link rel="stylesheet" type="text/css"
href="/scripts/includes/metstyle.css">

<!-- Page Header info goes here -->

<table width="100%" border="0" cellpadding="0" cellspacing="0">
<!-- Left hand header graphic goes here -->
<tr>
<td class="greenborders">
<a href ="http://www.met.rdg.ac.uk/" alt="Meteorology Department Home Page">
<img src="http://www.met.rdg.ac.uk/images/metdeptleft.jpg" border ="0">
</A>
</td>

<!-- Right hand header graphic or text goes here -->
<td class="greenborders" align=right>
<img src="http://www.met.rdg.ac.uk/images/metpicturesright.gif">
</td>
</tr>

<style>
..Caption {
font-size: 12pt
font-family: sans-serif;
font-weight: bold;
color: #447744;
}
</style>

<!-- End of page header section -->

<!--Crumbtrail or Quicklink topmenu bar data goes here -->
<tr>
<td colspan="2" class="greenbordersbgc">
<smallgreen>Location: <a
href="http://www.metnt.rdg.ac.uk/scripts/meetings/admin.aspx"
class="breadcrumbs">Met Dept Seminars Admin Page</a>
</td>
</tr>

</table>
<BR>

<center>

<H3>Met Dept Seminars Admin Page</H3>

<form RunAt="server">

<table cellspacing="10">

<tr>

<td valign="top">
<asp:FormView ID="MeetingsFormView"
DataSourceID="MeetingsDetailsAccessDataSource"
DataKeyNames="ID"
Gridlines="Both"
OnItemUpdated="MeetingsFormView_ItemUpdated"
OnItemDeleted="MeetingsFormView_ItemDeleted"
RunAt="server">

<HeaderStyle backcolor="Navy"
forecolor="White"/>

<RowStyle backcolor="White"/>

<EditRowStyle backcolor="LightCyan"/>

<ItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%#
Eval("ID") %></td></tr>
<tr><td align=right><B>Seminar Title:</B></td>
<td><%# Eval("SeminarTitle") %></td></tr>
<tr><td align=right><B>Speaker:</B></td <td><%#
Eval("Speaker") %></td></tr>
<tr><td align=right><B>Speaker Email:</B></td>
<td><%# Eval("SpeakerEmail") %></td></tr>
<tr><td align=right><B>Speaker
Institution:</B></td <td><%# Eval("SpeakerInstitution") %></td></tr>
<tr><td align=right><B>Seminar Date:</B></td>
<td><%# Eval("SeminarDate") %></td></tr>
<tr><td align=right><B>Seminar Time:</B></td>
<td><%# Eval("SeminarTime") %></td></tr>
<tr><td align=right><B>Seminar Location:</B></td>
<td><%# Eval("SeminarLocation") %></td></tr>
<tr><td align=right><B>Seminar Details:</B></td>
<td><%# Eval("SeminarDetails") %></td></tr>
<tr><td align=right><B>Seminar Host:</B></td>
<td><%# Eval("SeminarHost") %></td></tr>
<tr><td align=right><B>Seminar Host Email:</B></td>
<td><%# Eval("SeminarHostEmail") %></td></tr>
<tr><td align=right><B>Seminar Type:</B></td>
<td><%# Eval("SeminarType") %></td></tr>
<tr><td align=right><B>Organisation Notes:</B></td>
<td><%# Eval("OrganisationNotes") %></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="EditButton"
Text="Edit"
CommandName="Edit"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="NewButton"
Text="New"
CommandName="New"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="DeleteButton"
Text="Delete"
CommandName="Delete"
RunAt="server"/>
</td>
</tr>
</table>
</ItemTemplate>

<EditItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%#
Eval("ID") %></td></tr>

<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="EditSeminarTitleTextBox"
Text='<%# Bind("SeminarTitle")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="EditSpeakerTextBox"
Text='<%# Bind("Speaker") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="EditSpeakerEmailTextBox"
Text='<%# Bind("SpeakerEmail")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="EditSpeakerInstitutionTextBox"
Text='<%#
Bind("SpeakerInstitution") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="EditSeminarDateTextBox"
Text='<%# Bind("SeminarDate") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="EditSeminarTimeTextBox"
Text='<%# Bind("SeminarTime") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="EditSeminarLocationTextBox"
Text='<%#
Bind("SeminarLocation") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="EditSeminarDetailsTextBox"
Text='<%#
Bind("SeminarDetails") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="EditSeminarHostTextBox"
Text='<%# Bind("SeminarHost") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox ID="EditSeminarHostEmailTextBox"
Text='<%#
Bind("SeminarHostEmail") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="EditSeminarTypeTextBox"
Text='<%# Bind("SeminarType") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox ID="EditOrganisationNotesTextBox"
Text='<%#
Bind("OrganisationNotes") %>'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="UpdateButton"
Text="Update"
CommandName="Update"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelUpdateButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</EditItemTemplate>

<InsertItemTemplate>
<table>
<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="InsertSeminarTitleTextBox"
Text='Seminar Title'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="InsertSpeakerTextBox"
Text='Speaker Name'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="InsertSpeakerEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="InsertSpeakerInstitutionTextBox"
Text='Reading Meteorlogy Dept'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="InsertSeminarDateTextBox"
Text='1/1/2006'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="InsertSeminarTimeTextBox"
Text='12.00'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="InsertSeminarLocationTextBox"
Text='Sutcliffe Lecture
Theatre (GU01)'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="InsertSeminarDetailsTextBox"
Text='Add some Seminar Details'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="InsertSeminarHostTextBox"
Text='Seminar Host'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox
ID="InsertSeminarHostEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="InsertSeminarTypeTextBox"
Text='Lunchtime Seminar'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox
ID="InsertOrganisationNotesTextBox"
Text='Organisation Notes'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="InsertButton"
Text="Insert"
CommandName="Insert"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelInsertButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</InsertItemTemplate>

</asp:FormView>

</td>
</tr>
<tr>
<td>
<asp:GridView ID="MeetingsGridView"
DataSourceID="MeetingsAccessDataSource"
AutoGenerateColumns="false"
DataKeyNames="ID"

OnSelectedIndexChanged="MeetingsGridView_OnSelecte dIndexChanged"
RunAt="Server">

<HeaderStyle backcolor="cornsilk"
forecolor="Black" />

<Columns>

<asp:ButtonField Text="Show Details."
HeaderText="Show<BR>Details"
CommandName="Select"/>

<asp:BoundField DataField="ID" HeaderText="Item ID"/>
<asp:BoundField DataField="SeminarTitle"
HeaderText="Seminar Title"/>
<asp:BoundField DataField="Speaker"
HeaderText="Speaker"/>
<asp:BoundField DataField="SpeakerEmail" HeaderText="Speaker Email"/>
<asp:BoundField DataField="SpeakerInstitution" HeaderText="Speaker
Institution"/>
<asp:BoundField DataField="SeminarDate" HeaderText="Seminar Date"/>
<asp:BoundField DataField="SeminarTime" HeaderText="Seminar
Time"/>
<asp:BoundField DataField="SeminarLocation"
HeaderText="Seminar Location"/>

</Columns>

</asp:GridView>

</td>

</tr>

</table>

<asp:AccessDataSource
id="MeetingsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList">

</asp:AccessDataSource>
<asp:AccessDataSource
id="MeetingsDetailsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList WHERE ID=@ID"

InsertCommand="INSERT INTO SeminarList
(ID,SeminarTitle,Speaker,SpeakerEmail,SpeakerInsti tution,SeminarDate,SeminarTime,SeminarLocation,Sem inarDetails,SeminarHost,SeminarHostEmail,SeminarTy pe,OrganisationNotes)
VALUES (@ID,
@SeminarTitle,@Speaker,@SpeakerEmail,@SpeakerInsti tution,@SeminarDate,@SeminarTime,@SeminarLocation, @SeminarDetails,@SeminarHost,@SeminarHostEmail,@Se minarType,@OrganisationNotes)"

UpdateCommand="UPDATE SeminarList SET
SeminarTitle=@SeminarTitle,Speaker=@Speaker,Speake rEmail=@SpeakerEmail,SpeakerInstitution=@SpeakerIn stitution,SeminarDate=@SeminarDate,SeminarTime=@Se minarTime,SeminarLocation=@SeminarLocation,Seminar Details=@SeminarDetails,SeminarHost=@SeminarHost,S eminarHostEmail=@SeminarHostEmail,SeminarType=@Sem inarType,OrganisationNotes=@OrganisationNotes
WHERE ID=@ID"

DeleteCommand="DELETE FROM SeminarList WHERE ID=@ID"

OnInserted="MeetingsDetailsAccessDataSource_OnInse rted">
<SelectParameters>
<asp:QueryStringParameter Name="ID" Type="Int32"
QueryStringField="ID" />

</SelectParameters>

<InsertParameters>
<asp:Parameter Name="SeminarTitle" Direction="Output" Type="String"
DefaultValue="Seminar Title" />
<asp:Parameter Name="Speaker" Direction="Output" Type="String"
DefaultValue="Speaker" />
<asp:Parameter Name="SpeakerEmail" Direction="Output" Type="String"
DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SpeakerInstitution" Direction="Output"
Type="String" DefaultValue="Speaker Institution" />
<asp:Parameter Name="SeminarDate" Direction="Output"
Type="DateTime" DefaultValue="1/1/2006" />
<asp:Parameter Name="SeminarTime" Direction="Output" Type="String"
DefaultValue="12.00" />
<asp:Parameter Name="SeminarLocation" Direction="Output"
Type="String" DefaultValue="Seminar Location" />
<asp:Parameter Name="SeminarDetails" Direction="Output"
Type="String" DefaultValue="Seminar Details" />
<asp:Parameter Name="SeminarHost" Direction="Output" Type="String"
DefaultValue="Seminar Host" />
<asp:Parameter Name="SeminarHostEmail" Direction="Output"
Type="String" DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SeminarType" Direction="Output" Type="String"
DefaultValue="Lunchtime Seminar" />
<asp:Parameter Name="OrganisationNotes" Direction="Output"
Type="String" DefaultValue="Organisation Notes" />
</InsertParameters>

</asp:AccessDataSource>

</form>

</center>

</body>

</html>


The problem

Delete and Modify work fine but the add record function causes an error.
The Error.....

Server Error in '/' Application.
An OleDbParameter with ParameterName '@ID' is not contained by this
OleDbParameterCollection.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.IndexOutOfRangeException: An OleDbParameter
with ParameterName '@ID' is not contained by this OleDbParameterCollection.

Source Error:

Line 56: System.Data.Common.DbCommand command = e.Command;
Line 57:
Line 58:
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();
Line 59:
Line 60: Response.Write(ID);
Source File: c:\Inetpub\wwwroot\Scripts\meetings\admin.aspx Line: 58

Stack Trace:

[IndexOutOfRangeException: An OleDbParameter with ParameterName '@ID' is
not contained by this OleDbParameterCollection.]
System.Data.OleDb.OleDbParameterCollection.GetPara meter(String
parameterName) +988993
System.Data.Common.DbParameterCollection.get_Item( String
parameterName) +7

ASP.scripts_meetings_admin_aspx.MeetingsDetailsAcc essDataSource_OnInserted(Object
sender, SqlDataSourceStatusEventArgs e) in
c:\Inetpub\wwwroot\Scripts\meetings\admin.aspx:58

System.Web.UI.WebControls.SqlDataSourceView.OnInse rted(SqlDataSourceStatusEventArgs
e) +114

System.Web.UI.WebControls.SqlDataSourceView.Execut eDbCommand(DbCommand
command, DataSourceOperation operation) +375

System.Web.UI.WebControls.SqlDataSourceView.Execut eInsert(IDictionary
values) +447
System.Web.UI.DataSourceView.Insert(IDictionary values,
DataSourceViewOperationCallback callback) +72
System.Web.UI.WebControls.FormView.HandleInsert(St ring commandArg,
Boolean causesValidation) +388
System.Web.UI.WebControls.FormView.HandleEvent(Eve ntArgs e, Boolean
causesValidation, String validationGroup) +623
System.Web.UI.WebControls.FormView.OnBubbleEvent(O bject source,
EventArgs e) +95
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs
args) +35
System.Web.UI.WebControls.FormViewRow.OnBubbleEven t(Object source,
EventArgs e) +109
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs
args) +35
System.Web.UI.WebControls.LinkButton.OnCommand(Com mandEventArgs e) +115
System.Web.UI.WebControls.LinkButton.RaisePostBack Event(String
eventArgument) +163

System.Web.UI.WebControls.LinkButton.System.Web.UI .IPostBackEventHandler.RaisePostBackEvent(String
eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +174
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102
Oct 5 '06 #1
2 2930
Just checking whether your database uses ID as an autonumber field. In that
case, you wouldn't want to insert ID.

"DC" <DC@dontbother.comwrote in message
news:eg**********@south.jnrs.ja.net...
The Code

<%@ import namespace="System" %>
<%@ import namespace="System.Web" %>
<%@ import namespace="System.Web.UI" %>
<%@ import namespace="System.Web.UI.HtmlControls" %>
<%@ import namespace="System.Web.UI.WebControls" %>
<%@ import namespace="System.Data" %>
<%@ import namespace="System.Data.OleDb" %>

<html>
<head>

<title>Meetings Admin Page</title>

<meta NAME="keywords" CONTENT="Meetings">

<meta NAME="description" CONTENT="Meetings Admin Page">

<link REL="ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">
<link REL="SHORTCUT ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">

<meta name="MSSmartTagsPreventParsing" content="TRUE">

<script language="C#" runat="server">

public void Page_Load(object sender, System.EventArgs e)
{
if (Page.IsPostBack != true)
{

}
}

void MeetingsGridView_OnSelectedIndexChanged(Object sender, EventArgs e)
{
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
MeetingsGridView.SelectedValue.ToString();
MeetingsFormView.DataBind();
}
void MeetingsFormView_ItemUpdated(Object sender,
FormViewUpdatedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsFormView_ItemDeleted(Object sender,
FormViewDeletedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsDetailsAccessDataSource_OnInserted(Object sender,
SqlDataSourceStatusEventArgs e)
{

System.Data.Common.DbCommand command = e.Command;

MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();

Response.Write(ID);

MeetingsGridView.DataBind();
MeetingsFormView.DataBind();

}
</script>
</head>

<body bgcolor=#FFFFFF>

<!-- Start of page header section -->

<!-- Stylesheet Location -->

<link rel="stylesheet" type="text/css" href="/scripts/includes/style.css">

<!-- Page Header info goes here -->

<BR>

<center>

<H3>Seminars Admin Page</H3>

<form RunAt="server">

<table cellspacing="10">

<tr>

<td valign="top">
<asp:FormView ID="MeetingsFormView"
DataSourceID="MeetingsDetailsAccessDataSource"
DataKeyNames="ID"
Gridlines="Both"
OnItemUpdated="MeetingsFormView_ItemUpdated"
OnItemDeleted="MeetingsFormView_ItemDeleted"
RunAt="server">

<HeaderStyle backcolor="Navy"
forecolor="White"/>

<RowStyle backcolor="White"/>

<EditRowStyle backcolor="LightCyan"/>

<ItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%# Eval("ID")
%></td></tr>
<tr><td align=right><B>Seminar Title:</B></td<td><%#
Eval("SeminarTitle") %></td></tr>
<tr><td align=right><B>Speaker:</B></td <td><%#
Eval("Speaker") %></td></tr>
<tr><td align=right><B>Speaker Email:</B></td<td><%#
Eval("SpeakerEmail") %></td></tr>
<tr><td align=right><B>Speaker Institution:</B></td>
<td><%# Eval("SpeakerInstitution") %></td></tr>
<tr><td align=right><B>Seminar Date:</B></td<td><%#
Eval("SeminarDate") %></td></tr>
<tr><td align=right><B>Seminar Time:</B></td<td><%#
Eval("SeminarTime") %></td></tr>
<tr><td align=right><B>Seminar Location:</B></td>
<td><%# Eval("SeminarLocation") %></td></tr>
<tr><td align=right><B>Seminar Details:</B></td>
<td><%# Eval("SeminarDetails") %></td></tr>
<tr><td align=right><B>Seminar Host:</B></td<td><%#
Eval("SeminarHost") %></td></tr>
<tr><td align=right><B>Seminar Host Email:</B></td>
<td><%# Eval("SeminarHostEmail") %></td></tr>
<tr><td align=right><B>Seminar Type:</B></td<td><%#
Eval("SeminarType") %></td></tr>
<tr><td align=right><B>Organisation Notes:</B></td>
<td><%# Eval("OrganisationNotes") %></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="EditButton"
Text="Edit"
CommandName="Edit"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="NewButton"
Text="New"
CommandName="New"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="DeleteButton"
Text="Delete"
CommandName="Delete"
RunAt="server"/>
</td>
</tr>
</table>
</ItemTemplate>

<EditItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%# Eval("ID")
%></td></tr>

<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="EditSeminarTitleTextBox"
Text='<%# Bind("SeminarTitle")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="EditSpeakerTextBox"
Text='<%# Bind("Speaker") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="EditSpeakerEmailTextBox"
Text='<%# Bind("SpeakerEmail")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="EditSpeakerInstitutionTextBox"
Text='<%#
Bind("SpeakerInstitution") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="EditSeminarDateTextBox"
Text='<%# Bind("SeminarDate") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="EditSeminarTimeTextBox"
Text='<%# Bind("SeminarTime") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="EditSeminarLocationTextBox"
Text='<%# Bind("SeminarLocation")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="EditSeminarDetailsTextBox"
Text='<%# Bind("SeminarDetails")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="EditSeminarHostTextBox"
Text='<%# Bind("SeminarHost") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox ID="EditSeminarHostEmailTextBox"
Text='<%#
Bind("SeminarHostEmail") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="EditSeminarTypeTextBox"
Text='<%# Bind("SeminarType") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox ID="EditOrganisationNotesTextBox"
Text='<%#
Bind("OrganisationNotes") %>'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="UpdateButton"
Text="Update"
CommandName="Update"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelUpdateButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</EditItemTemplate>

<InsertItemTemplate>
<table>
<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="InsertSeminarTitleTextBox"
Text='Seminar Title'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="InsertSpeakerTextBox"
Text='Speaker Name'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="InsertSpeakerEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="InsertSpeakerInstitutionTextBox"
Text='Reading Meteorlogy Dept'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="InsertSeminarDateTextBox"
Text='1/1/2006'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="InsertSeminarTimeTextBox"
Text='12.00'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="InsertSeminarLocationTextBox"
Text='Sutcliffe Lecture Theatre
(GU01)'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="InsertSeminarDetailsTextBox"
Text='Add some Seminar Details'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="InsertSeminarHostTextBox"
Text='Seminar Host'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox
ID="InsertSeminarHostEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="InsertSeminarTypeTextBox"
Text='Lunchtime Seminar'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox
ID="InsertOrganisationNotesTextBox"
Text='Organisation Notes'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="InsertButton"
Text="Insert"
CommandName="Insert"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelInsertButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</InsertItemTemplate>

</asp:FormView>

</td>
</tr>
<tr>
<td>
<asp:GridView ID="MeetingsGridView"
DataSourceID="MeetingsAccessDataSource"
AutoGenerateColumns="false"
DataKeyNames="ID"

OnSelectedIndexChanged="MeetingsGridView_OnSelecte dIndexChanged"
RunAt="Server">

<HeaderStyle backcolor="cornsilk"
forecolor="Black" />

<Columns>

<asp:ButtonField Text="Show Details."
HeaderText="Show<BR>Details"
CommandName="Select"/>

<asp:BoundField DataField="ID" HeaderText="Item ID"/>
<asp:BoundField DataField="SeminarTitle"
HeaderText="Seminar Title"/>
<asp:BoundField DataField="Speaker"
HeaderText="Speaker"/>
<asp:BoundField DataField="SpeakerEmail" HeaderText="Speaker Email"/>
<asp:BoundField DataField="SpeakerInstitution" HeaderText="Speaker
Institution"/>
<asp:BoundField DataField="SeminarDate" HeaderText="Seminar Date"/>
<asp:BoundField DataField="SeminarTime" HeaderText="Seminar
Time"/>
<asp:BoundField DataField="SeminarLocation" HeaderText="Seminar
Location"/>

</Columns>

</asp:GridView>

</td>

</tr>

</table>

<asp:AccessDataSource
id="MeetingsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList">

</asp:AccessDataSource>
<asp:AccessDataSource
id="MeetingsDetailsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList WHERE ID=@ID"

InsertCommand="INSERT INTO SeminarList
(ID,SeminarTitle,Speaker,SpeakerEmail,SpeakerInsti tution,SeminarDate,SeminarTime,SeminarLocation,Sem inarDetails,SeminarHost,SeminarHostEmail,SeminarTy pe,OrganisationNotes)
VALUES (@ID,
@SeminarTitle,@Speaker,@SpeakerEmail,@SpeakerInsti tution,@SeminarDate,@SeminarTime,@SeminarLocation, @SeminarDetails,@SeminarHost,@SeminarHostEmail,@Se minarType,@OrganisationNotes)"

UpdateCommand="UPDATE SeminarList SET
SeminarTitle=@SeminarTitle,Speaker=@Speaker,Speake rEmail=@SpeakerEmail,SpeakerInstitution=@SpeakerIn stitution,SeminarDate=@SeminarDate,SeminarTime=@Se minarTime,SeminarLocation=@SeminarLocation,Seminar Details=@SeminarDetails,SeminarHost=@SeminarHost,S eminarHostEmail=@SeminarHostEmail,SeminarType=@Sem inarType,OrganisationNotes=@OrganisationNotes
WHERE ID=@ID"

DeleteCommand="DELETE FROM SeminarList WHERE ID=@ID"

OnInserted="MeetingsDetailsAccessDataSource_OnInse rted">
<SelectParameters>
<asp:QueryStringParameter Name="ID" Type="Int32" QueryStringField="ID"
/>

</SelectParameters>

<InsertParameters>
<asp:Parameter Name="SeminarTitle" Direction="Output" Type="String"
DefaultValue="Seminar Title" />
<asp:Parameter Name="Speaker" Direction="Output" Type="String"
DefaultValue="Speaker" />
<asp:Parameter Name="SpeakerEmail" Direction="Output" Type="String"
DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SpeakerInstitution" Direction="Output"
Type="String" DefaultValue="Speaker Institution" />
<asp:Parameter Name="SeminarDate" Direction="Output" Type="DateTime"
DefaultValue="1/1/2006" />
<asp:Parameter Name="SeminarTime" Direction="Output" Type="String"
DefaultValue="12.00" />
<asp:Parameter Name="SeminarLocation" Direction="Output" Type="String"
DefaultValue="Seminar Location" />
<asp:Parameter Name="SeminarDetails" Direction="Output" Type="String"
DefaultValue="Seminar Details" />
<asp:Parameter Name="SeminarHost" Direction="Output" Type="String"
DefaultValue="Seminar Host" />
<asp:Parameter Name="SeminarHostEmail" Direction="Output"
Type="String" DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SeminarType" Direction="Output" Type="String"
DefaultValue="Lunchtime Seminar" />
<asp:Parameter Name="OrganisationNotes" Direction="Output"
Type="String" DefaultValue="Organisation Notes" />
</InsertParameters>

</asp:AccessDataSource>

</form>

</center>

</body>

</html><%@ import namespace="System" %>
<%@ import namespace="System.Web" %>
<%@ import namespace="System.Web.UI" %>
<%@ import namespace="System.Web.UI.HtmlControls" %>
<%@ import namespace="System.Web.UI.WebControls" %>
<%@ import namespace="System.Data" %>
<%@ import namespace="System.Data.OleDb" %>

<html>
<head>

<title>Meteorology Department Meetings Admin Page</title>

<meta NAME="keywords" CONTENT="meteorology dept, Meetings">

<meta NAME="description" CONTENT="Meteorology Department Meetings Admin
Page">
<meta NAME="htdig-email" CONTENT="we****@met.rdg.ac.uk">

<META HTTP-EQUIV=REFRESH CONTENT=1800>

<link REL="ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">
<link REL="SHORTCUT ICON" HREF="http://www.met.rdg.ac.uk/favicon.ico">

<meta name="MSSmartTagsPreventParsing" content="TRUE">

<script language="C#" runat="server">

public void Page_Load(object sender, System.EventArgs e)
{
if (Page.IsPostBack != true)
{

}
}

void MeetingsGridView_OnSelectedIndexChanged(Object sender, EventArgs e)
{
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
MeetingsGridView.SelectedValue.ToString();
MeetingsFormView.DataBind();
}
void MeetingsFormView_ItemUpdated(Object sender,
FormViewUpdatedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsFormView_ItemDeleted(Object sender,
FormViewDeletedEventArgs e)
{
MeetingsGridView.DataBind();
}

void MeetingsDetailsAccessDataSource_OnInserted(Object sender,
SqlDataSourceStatusEventArgs e)
{

System.Data.Common.DbCommand command = e.Command;

MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();

Response.Write(ID);

MeetingsGridView.DataBind();
MeetingsFormView.DataBind();

}
</script>
</head>

<body bgcolor=#FFFFFF>

<!-- Start of page header section -->

<!-- Stylesheet Location -->

<link rel="stylesheet" type="text/css"
href="/scripts/includes/metstyle.css">

<!-- Page Header info goes here -->

<table width="100%" border="0" cellpadding="0" cellspacing="0">
<!-- Left hand header graphic goes here -->
<tr>
<td class="greenborders">
<a href ="http://www.met.rdg.ac.uk/" alt="Meteorology Department Home
Page">
<img src="http://www.met.rdg.ac.uk/images/metdeptleft.jpg" border ="0">
</A>
</td>

<!-- Right hand header graphic or text goes here -->
<td class="greenborders" align=right>
<img src="http://www.met.rdg.ac.uk/images/metpicturesright.gif">
</td>
</tr>

<style>
.Caption {
font-size: 12pt
font-family: sans-serif;
font-weight: bold;
color: #447744;
}
</style>

<!-- End of page header section -->

<!--Crumbtrail or Quicklink topmenu bar data goes here -->
<tr>
<td colspan="2" class="greenbordersbgc">
<smallgreen>Location: <a
href="http://www.metnt.rdg.ac.uk/scripts/meetings/admin.aspx"
class="breadcrumbs">Met Dept Seminars Admin Page</a>
</td>
</tr>

</table>
<BR>

<center>

<H3>Met Dept Seminars Admin Page</H3>

<form RunAt="server">

<table cellspacing="10">

<tr>

<td valign="top">
<asp:FormView ID="MeetingsFormView"
DataSourceID="MeetingsDetailsAccessDataSource"
DataKeyNames="ID"
Gridlines="Both"
OnItemUpdated="MeetingsFormView_ItemUpdated"
OnItemDeleted="MeetingsFormView_ItemDeleted"
RunAt="server">

<HeaderStyle backcolor="Navy"
forecolor="White"/>

<RowStyle backcolor="White"/>

<EditRowStyle backcolor="LightCyan"/>

<ItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%# Eval("ID")
%></td></tr>
<tr><td align=right><B>Seminar Title:</B></td<td><%#
Eval("SeminarTitle") %></td></tr>
<tr><td align=right><B>Speaker:</B></td <td><%#
Eval("Speaker") %></td></tr>
<tr><td align=right><B>Speaker Email:</B></td<td><%#
Eval("SpeakerEmail") %></td></tr>
<tr><td align=right><B>Speaker Institution:</B></td>
<td><%# Eval("SpeakerInstitution") %></td></tr>
<tr><td align=right><B>Seminar Date:</B></td<td><%#
Eval("SeminarDate") %></td></tr>
<tr><td align=right><B>Seminar Time:</B></td<td><%#
Eval("SeminarTime") %></td></tr>
<tr><td align=right><B>Seminar Location:</B></td>
<td><%# Eval("SeminarLocation") %></td></tr>
<tr><td align=right><B>Seminar Details:</B></td>
<td><%# Eval("SeminarDetails") %></td></tr>
<tr><td align=right><B>Seminar Host:</B></td<td><%#
Eval("SeminarHost") %></td></tr>
<tr><td align=right><B>Seminar Host Email:</B></td>
<td><%# Eval("SeminarHostEmail") %></td></tr>
<tr><td align=right><B>Seminar Type:</B></td<td><%#
Eval("SeminarType") %></td></tr>
<tr><td align=right><B>Organisation Notes:</B></td>
<td><%# Eval("OrganisationNotes") %></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="EditButton"
Text="Edit"
CommandName="Edit"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="NewButton"
Text="New"
CommandName="New"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="DeleteButton"
Text="Delete"
CommandName="Delete"
RunAt="server"/>
</td>
</tr>
</table>
</ItemTemplate>

<EditItemTemplate>
<table>
<tr><td align=right><B>ID:</B></td><td><%# Eval("ID")
%></td></tr>

<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="EditSeminarTitleTextBox"
Text='<%# Bind("SeminarTitle")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="EditSpeakerTextBox"
Text='<%# Bind("Speaker") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="EditSpeakerEmailTextBox"
Text='<%# Bind("SpeakerEmail")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="EditSpeakerInstitutionTextBox"
Text='<%#
Bind("SpeakerInstitution") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="EditSeminarDateTextBox"
Text='<%# Bind("SeminarDate") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="EditSeminarTimeTextBox"
Text='<%# Bind("SeminarTime") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="EditSeminarLocationTextBox"
Text='<%# Bind("SeminarLocation")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="EditSeminarDetailsTextBox"
Text='<%# Bind("SeminarDetails")
%>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="EditSeminarHostTextBox"
Text='<%# Bind("SeminarHost") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox ID="EditSeminarHostEmailTextBox"
Text='<%#
Bind("SeminarHostEmail") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="EditSeminarTypeTextBox"
Text='<%# Bind("SeminarType") %>'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox ID="EditOrganisationNotesTextBox"
Text='<%#
Bind("OrganisationNotes") %>'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="UpdateButton"
Text="Update"
CommandName="Update"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelUpdateButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</EditItemTemplate>

<InsertItemTemplate>
<table>
<tr><td align=right><B>Seminar Title:</B></td>
<td><asp:TextBox ID="InsertSeminarTitleTextBox"
Text='Seminar Title'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker:</B></td>
<td><asp:TextBox ID="InsertSpeakerTextBox"
Text='Speaker Name'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Email:</B></td>
<td><asp:TextBox ID="InsertSpeakerEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Speaker Institution:</B></td>
<td><asp:TextBox
ID="InsertSpeakerInstitutionTextBox"
Text='Reading Meteorlogy Dept'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Date:</B></td>
<td><asp:TextBox ID="InsertSeminarDateTextBox"
Text='1/1/2006'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Time:</B></td>
<td><asp:TextBox ID="InsertSeminarTimeTextBox"
Text='12.00'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Location:</B></td>
<td><asp:TextBox ID="InsertSeminarLocationTextBox"
Text='Sutcliffe Lecture Theatre
(GU01)'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Details:</B></td>
<td><asp:TextBox ID="InsertSeminarDetailsTextBox"
Text='Add some Seminar Details'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host:</B></td>
<td><asp:TextBox ID="InsertSeminarHostTextBox"
Text='Seminar Host'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Host Email:</B></td>
<td><asp:TextBox
ID="InsertSeminarHostEmailTextBox"
Te***********@rdg.ac.uk'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Seminar Type:</B></td>
<td><asp:TextBox ID="InsertSeminarTypeTextBox"
Text='Lunchtime Seminar'
RunAt="Server" /></td></tr>

<tr><td align=right><B>Organisation Notes:</B></td>
<td><asp:TextBox
ID="InsertOrganisationNotesTextBox"
Text='Organisation Notes'
RunAt="Server" /></td></tr>

<tr>
<td colspan="2">
<asp:LinkButton ID="InsertButton"
Text="Insert"
CommandName="Insert"
RunAt="server"/>
&nbsp;
<asp:LinkButton ID="CancelInsertButton"
Text="Cancel"
CommandName="Cancel"
RunAt="server"/>
</td>
</tr>
</table>
</InsertItemTemplate>

</asp:FormView>

</td>
</tr>
<tr>
<td>
<asp:GridView ID="MeetingsGridView"
DataSourceID="MeetingsAccessDataSource"
AutoGenerateColumns="false"
DataKeyNames="ID"

OnSelectedIndexChanged="MeetingsGridView_OnSelecte dIndexChanged"
RunAt="Server">

<HeaderStyle backcolor="cornsilk"
forecolor="Black" />

<Columns>

<asp:ButtonField Text="Show Details."
HeaderText="Show<BR>Details"
CommandName="Select"/>

<asp:BoundField DataField="ID" HeaderText="Item ID"/>
<asp:BoundField DataField="SeminarTitle"
HeaderText="Seminar Title"/>
<asp:BoundField DataField="Speaker"
HeaderText="Speaker"/>
<asp:BoundField DataField="SpeakerEmail" HeaderText="Speaker Email"/>
<asp:BoundField DataField="SpeakerInstitution" HeaderText="Speaker
Institution"/>
<asp:BoundField DataField="SeminarDate" HeaderText="Seminar Date"/>
<asp:BoundField DataField="SeminarTime" HeaderText="Seminar
Time"/>
<asp:BoundField DataField="SeminarLocation" HeaderText="Seminar
Location"/>

</Columns>

</asp:GridView>

</td>

</tr>

</table>

<asp:AccessDataSource
id="MeetingsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList">

</asp:AccessDataSource>
<asp:AccessDataSource
id="MeetingsDetailsAccessDataSource"
runat="server"
datasourcemode="DataSet"
DataFile="C:\\Program Files\\Common Files\\ODBC\\Data
Sources\\seminars.mdb"

SelectCommand="SELECT * FROM SeminarList WHERE ID=@ID"

InsertCommand="INSERT INTO SeminarList
(ID,SeminarTitle,Speaker,SpeakerEmail,SpeakerInsti tution,SeminarDate,SeminarTime,SeminarLocation,Sem inarDetails,SeminarHost,SeminarHostEmail,SeminarTy pe,OrganisationNotes)
VALUES (@ID,
@SeminarTitle,@Speaker,@SpeakerEmail,@SpeakerInsti tution,@SeminarDate,@SeminarTime,@SeminarLocation, @SeminarDetails,@SeminarHost,@SeminarHostEmail,@Se minarType,@OrganisationNotes)"

UpdateCommand="UPDATE SeminarList SET
SeminarTitle=@SeminarTitle,Speaker=@Speaker,Speake rEmail=@SpeakerEmail,SpeakerInstitution=@SpeakerIn stitution,SeminarDate=@SeminarDate,SeminarTime=@Se minarTime,SeminarLocation=@SeminarLocation,Seminar Details=@SeminarDetails,SeminarHost=@SeminarHost,S eminarHostEmail=@SeminarHostEmail,SeminarType=@Sem inarType,OrganisationNotes=@OrganisationNotes
WHERE ID=@ID"

DeleteCommand="DELETE FROM SeminarList WHERE ID=@ID"

OnInserted="MeetingsDetailsAccessDataSource_OnInse rted">
<SelectParameters>
<asp:QueryStringParameter Name="ID" Type="Int32" QueryStringField="ID"
/>

</SelectParameters>

<InsertParameters>
<asp:Parameter Name="SeminarTitle" Direction="Output" Type="String"
DefaultValue="Seminar Title" />
<asp:Parameter Name="Speaker" Direction="Output" Type="String"
DefaultValue="Speaker" />
<asp:Parameter Name="SpeakerEmail" Direction="Output" Type="String"
DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SpeakerInstitution" Direction="Output"
Type="String" DefaultValue="Speaker Institution" />
<asp:Parameter Name="SeminarDate" Direction="Output" Type="DateTime"
DefaultValue="1/1/2006" />
<asp:Parameter Name="SeminarTime" Direction="Output" Type="String"
DefaultValue="12.00" />
<asp:Parameter Name="SeminarLocation" Direction="Output" Type="String"
DefaultValue="Seminar Location" />
<asp:Parameter Name="SeminarDetails" Direction="Output" Type="String"
DefaultValue="Seminar Details" />
<asp:Parameter Name="SeminarHost" Direction="Output" Type="String"
DefaultValue="Seminar Host" />
<asp:Parameter Name="SeminarHostEmail" Direction="Output"
Type="String" DefaultValue="so*****@rdg.ac.uk" />
<asp:Parameter Name="SeminarType" Direction="Output" Type="String"
DefaultValue="Lunchtime Seminar" />
<asp:Parameter Name="OrganisationNotes" Direction="Output"
Type="String" DefaultValue="Organisation Notes" />
</InsertParameters>

</asp:AccessDataSource>

</form>

</center>

</body>

</html>


The problem

Delete and Modify work fine but the add record function causes an error.
The Error.....

Server Error in '/' Application.
An OleDbParameter with ParameterName '@ID' is not contained by this
OleDbParameterCollection.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.IndexOutOfRangeException: An OleDbParameter with
ParameterName '@ID' is not contained by this OleDbParameterCollection.

Source Error:

Line 56: System.Data.Common.DbCommand command = e.Command;
Line 57:
Line 58:
MeetingsDetailsAccessDataSource.SelectParameters["ID"].DefaultValue =
command.Parameters["@ID"].Value.ToString();
Line 59:
Line 60: Response.Write(ID);
Source File: c:\Inetpub\wwwroot\Scripts\meetings\admin.aspx Line: 58

Stack Trace:

[IndexOutOfRangeException: An OleDbParameter with ParameterName '@ID' is
not contained by this OleDbParameterCollection.]
System.Data.OleDb.OleDbParameterCollection.GetPara meter(String
parameterName) +988993
System.Data.Common.DbParameterCollection.get_Item( String parameterName)
+7

ASP.scripts_meetings_admin_aspx.MeetingsDetailsAcc essDataSource_OnInserted(Object
sender, SqlDataSourceStatusEventArgs e) in
c:\Inetpub\wwwroot\Scripts\meetings\admin.aspx:58

System.Web.UI.WebControls.SqlDataSourceView.OnInse rted(SqlDataSourceStatusEventArgs
e) +114

System.Web.UI.WebControls.SqlDataSourceView.Execut eDbCommand(DbCommand
command, DataSourceOperation operation) +375

System.Web.UI.WebControls.SqlDataSourceView.Execut eInsert(IDictionary
values) +447
System.Web.UI.DataSourceView.Insert(IDictionary values,
DataSourceViewOperationCallback callback) +72
System.Web.UI.WebControls.FormView.HandleInsert(St ring commandArg,
Boolean causesValidation) +388
System.Web.UI.WebControls.FormView.HandleEvent(Eve ntArgs e, Boolean
causesValidation, String validationGroup) +623
System.Web.UI.WebControls.FormView.OnBubbleEvent(O bject source,
EventArgs e) +95
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args)
+35
System.Web.UI.WebControls.FormViewRow.OnBubbleEven t(Object source,
EventArgs e) +109
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args)
+35
System.Web.UI.WebControls.LinkButton.OnCommand(Com mandEventArgs e) +115
System.Web.UI.WebControls.LinkButton.RaisePostBack Event(String
eventArgument) +163

System.Web.UI.WebControls.LinkButton.System.Web.UI .IPostBackEventHandler.RaisePostBackEvent(String
eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData)
+174
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102

Oct 5 '06 #2
DC
Ken Cox [Microsoft MVP] wrote:
Just checking whether your database uses ID as an autonumber field. In that
case, you wouldn't want to insert ID.
Yes the access Database does use ID as an auto number field.
Oct 5 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: deko | last post by:
I use named anchors to take users to specific parts of a long page. But I want to add some processing and do some things with my nav bar when users go to certain sections delineated by named...
0
by: Mike C | last post by:
Hi. I'm just getting started with vb.NET development in VS 2003. I have a datagrid that lists a bunch of customers (hospitals). Next to the customer number and name is a bunch of checkboxes that I...
2
by: Lyn | last post by:
Hi, I am working on a genealogy project in which I have two tables: Person -- one record for each person in the family. Each record has a unique Autonum field (IDPerson). Partnerships -- one...
2
by: sarunnio | last post by:
Hi, I 've tried to work around with this long times ago. I have a template and the page loaded inside. When loading the page,the control ID contained with the page will be automatically...
4
by: Jorge | last post by:
Hello I have a stored procedure with several parameters and 2 are declared datatype Numeric as per the SQL table. When i try to use the following: Me.SqlCommand1.CommandType =...
2
by: PJ6 | last post by:
Is is possible to get the session ID in JavaScript when using ASP.NET in cookieless mode? The reason I ask is that one of the functions I want to perform using remote scripting (AJAX) is a page...
3
by: Mokka | last post by:
I just build a javascript function that writes some img tags into a layer on mouseover but i have a problem i don't know how to solve. Everything works fine if the user waits until the page is...
0
by: DC | last post by:
The problem I'm using the .NET GridView and FormView objects for the first time and im getting the error "An OleDbParameter with ParameterName '@ID' is not contained by this...
3
by: iskeletor | last post by:
#include <stdio.h> #include <string.h> #include <math.h> #include <stdlib.h> #define STUDENT_NUMBER 68 #define ARRAY_LENGTH 10 struct node{ char Name,Surname; int data,no;
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.