[RESOLVED] display real time data in label using MS acccess database

Hi,

 

I need to display the real time data in the label.

Explain In detail: 

The camera is counting the people and store the counted value in database every minute.

so i need to pick the data and display it same on the screen. There are lot of cameras counting. So i need to take camera number and display respective count.

 

Camera NUmber Counted Value
1 Label1(Display realtime data here)
2 Label2

Can anybody advice me how and which way i can achieve this

Thanks in advance

If you want to do it in WebApp. Do it with AJAX controls. Add a ScriptManager control on top, add update panel and labels in it to update from database. Add a AJAX timer control for continuous update at specified interval.

Hi,

Thanks for your reply

I did the same its shows an error : the name 'label1' doesnt exists in current context

I explain my code here:

<div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste"> <asp:ScriptManager ID="ScriptManager1" runat="server"></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">        </asp:ScriptManager> </div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">        <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode=Conditionals></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">        <ContentTemplate></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">            <asp:Timer ID="Timer1" runat="server" Interval="1000"></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">            </asp:Timer></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">            <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">        </ContentTemplate></div> <div style="position: absolute; left: -10000px; top: 26px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;" id="_mcePaste">        </asp:UpdatePanel></div>

 <asp:ScriptManager ID="ScriptManager1" runat="server">

        </asp:ScriptManager> 

        <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode=Conditionals>

        <ContentTemplate>

            <asp:Timer ID="Timer1" runat="server" Interval="1000" onTick="Timer_Click">

            </asp:Timer>

            <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>

        </ContentTemplate>

        </asp:UpdatePanel>


I check all way but still its through the same error. I'm using multiple UPDATEPANEL.

I'm using  15 updatepanel along with the timer to refresh and label to display data. But at .cs file i have used 

public void Timer_Click(object sender, EventArgs e)

{

  Dbcommection_Method();

Label1.Text = data ;

}


HERE it throughs "Label1" doesnt contain in current context


Thanks a lot

I think this is a Designer issue....delete the label control and re-add to the page....if still problem persists, then try by creating a new page and add controls one by one....

Thanks.

thoughts on "[RESOLVED] display real time data in label using MS acccess database"

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>