unable to access labels or submit button in formview

Posted on 2011-05-06
Last Modified: 2012-05-11
Hey guys.. i have my forumview set up

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="editpostadmin.aspx.vb" Inherits="forums_editpostadmin" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">

<html xmlns="">
<head runat="server">
    <title>Edit Post</title>
    <form id="form1" runat="server">
 <div class="style1">
        Edit Post<br />
        <asp:FormView ID="FormView1" runat="server" DataSourceID="AccessDataSource1">
<asp:TextBox id="title" runat="server" Text='<%#Eval("Title") %>' /> <br />
<asp:TextBox id="post" runat="server" Text='<%#Eval("Post") %>' TextMode="MultiLine" /><br />
        Important<asp:CheckBox ID="CheckBox1" runat="server" Checked='<%#Eval("important") %>' />
          &nbsp; Locked 
            <asp:CheckBox ID="CheckBox2" runat="server" Checked='<%#Eval("forumlock") %>'/> <br />
            <asp:Button ID="submit" runat="server" Text="submit" OnServerClick="SubmitBtn1_Click" /><br />
            <asp:Label ID="Label1" runat="server"
        <asp:AccessDataSource ID="AccessDataSource1" runat="server" 
            DataFile="~/forums/forum.mdb" SelectCommand="SELECT * FROM [forum] Where ID = @ID">
            <asp:QueryStringParameter Name="ID" QueryStringField="ID" />

Open in new window

but in my aspv.vb i cant access the label OR button???
Question by:runnerjp2005
    LVL 74

    Expert Comment

    by:käµfm³d 👽
    Of course not--they're inside an ItemTemplate, which means they don't *actually* exists until the databinding for the FormView occurs.

    What is it you are trying to do?
    LVL 83

    Expert Comment

    LVL 83

    Accepted Solution


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Suggested Solutions

    I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
    Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
    It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now