|
What is the scope of your timer, make sure its limited only for that specific page and not forcing a full page refresh.
|
|
|
|
|
when i run this code it show errors like "Type.'sysem.web.UI.Updaatepnael' doesnot have a public property named 'div','gridview'.......etc" plz chk code if there is any error
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<div id="divgrid" runat ="server" overflow:scroll style="position: absolute; width: 333px; height: 122px">
<asp:GridView ID="gvCouponDetails0" runat="server" AutoGenerateColumns="False"
CellPadding="4" ForeColor="#333333" GridLines="None"
onrowcancelingedit="gvCouponDetails_RowCancelingEdit"
onrowediting="gvCouponDetails_RowEditing"
onrowupdating="gvCouponDetails_RowUpdating"
style="top: 519px; left: 285px; position: absolute; height: 143px; width: 575px; z-index: 1; margin-left: 0px; margin-top: 0px;">
<FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
<RowStyle BackColor="#E3EAEB" />
<Columns>
<asp:CommandField ButtonType="Button" CancelText="C"
ControlStyle-Font-Size="10px" ControlStyle-ForeColor="Blue"
ControlStyle-Width="15px" EditText="E" ShowCancelButton="true"
ShowEditButton="true" UpdateText="U">
<ControlStyle Font-Size="10px" ForeColor="Blue" Width="15px" />
</asp:CommandField>
<asp:TemplateField HeaderText="Coupon Name">
<ItemTemplate>
<asp:Label ID="tbCouponName0" runat="server" Text='<%# Bind("CouponName") %>'
Width="100px" />
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList ID="ddlCoupon0" runat="server" DataSourceID="DSCouponType"
DataTextField="CouponName" DataValueField="Coupon_TypeID" Width="100px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Date">
<ItemTemplate>
<asp:Label ID="lblDate0" runat="server" Text='<%# Bind("Date") %>'
Width="65px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbDate0" runat="server" Text='<%# Bind("Date") %>'
Width="65px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Price">
<ItemTemplate>
<asp:Label ID="lblprice0" runat="server" Text='<%# Bind("Price") %>'
Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbprice0" runat="server" Text='<%# Bind("Price") %>'
Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="End">
<ItemTemplate>
<asp:Label ID="lblSerialEnd0" runat="server" Text='<%# Bind("SerialEnd") %>'
Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbSerialEnd0" runat="server" Text='<%# Bind("SerialEnd") %>'
Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Start">
<ItemTemplate>
<asp:Label ID="lblSerialStart0" runat="server"
Text='<%# Bind("SerialStart") %>' Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbSerialStart0" runat="server"
Text='<%# Bind("SerialStart") %>' Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Menu">
<ItemTemplate>
<asp:Label ID="tbMenu0" runat="server" Text='<%# Bind("CafeMenu") %>'
Width="80px" />
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList ID="ddlmenu0" runat="server" DataSourceID="DSMenu"
DataTextField="Cafe_Menu" DataValueField="Cafe_Menu" Width="80px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Description">
<ItemTemplate>
<asp:Label ID="lblDes0" runat="server" Text='<%# Bind("Description") %>'
Width="70px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbDes0" runat="server" Text='<%# Bind("Description") %>'
Width="70px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Transaction">
<ItemTemplate>
<asp:Label ID="lblTrans0" runat="server" Text='<%# Bind("Transaction") %>'
Width="70px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbTrans0" runat="server" Text='<%# Bind("Transaction") %>'
Width="70px" />
</EditItemTemplate>
</asp:TemplateField>
</Columns>
<PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#7C6F57" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
</div>
</asp:UpdatePanel>
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:Coupon ManagementConnectionString30 %>"
SelectCommand="SELECT * FROM [CouponTransaction]"></asp:SqlDataSource>
</asp:Content>
|
|
|
|
|
Enclose it in <ContentTemplate></ContentTemplate>
|
|
|
|
|
tHTS rIGHT wITH aRUN
uSE fOLLOWING cODE
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate >
<div id="divgrid" runat ="server" overflow:scroll style="position: absolute; width: 333px; height: 122px">
<asp:GridView ID="gvCouponDetails0" runat="server" AutoGenerateColumns="False"
CellPadding="4" ForeColor="#333333" GridLines="None"
onrowcancelingedit="gvCouponDetails_RowCancelingEdit"
onrowediting="gvCouponDetails_RowEditing"
onrowupdating="gvCouponDetails_RowUpdating"
style="top: 519px; left: 285px; position: absolute; height: 143px; width: 575px; z-index: 1; margin-left: 0px; margin-top: 0px;">
<FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
<RowStyle BackColor="#E3EAEB" />
<Columns>
<asp:CommandField ButtonType="Button" CancelText="C"
ControlStyle-Font-Size="10px" ControlStyle-ForeColor="Blue"
ControlStyle-Width="15px" EditText="E" ShowCancelButton="true"
ShowEditButton="true" UpdateText="U">
<ControlStyle Font-Size="10px" ForeColor="Blue" Width="15px" />
</asp:CommandField>
<asp:TemplateField HeaderText="Coupon Name">
<ItemTemplate>
<asp:Label ID="tbCouponName0" runat="server" Text='<%# Bind("CouponName") %>'
Width="100px" />
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList ID="ddlCoupon0" runat="server" DataSourceID="DSCouponType"
DataTextField="CouponName" DataValueField="Coupon_TypeID" Width="100px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Date">
<ItemTemplate>
<asp:Label ID="lblDate0" runat="server" Text='<%# Bind("Date") %>'
Width="65px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbDate0" runat="server" Text='<%# Bind("Date") %>'
Width="65px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Price">
<ItemTemplate>
<asp:Label ID="lblprice0" runat="server" Text='<%# Bind("Price") %>'
Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbprice0" runat="server" Text='<%# Bind("Price") %>'
Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="End">
<ItemTemplate>
<asp:Label ID="lblSerialEnd0" runat="server" Text='<%# Bind("SerialEnd") %>'
Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbSerialEnd0" runat="server" Text='<%# Bind("SerialEnd") %>'
Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Start">
<ItemTemplate>
<asp:Label ID="lblSerialStart0" runat="server"
Text='<%# Bind("SerialStart") %>' Width="50px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbSerialStart0" runat="server"
Text='<%# Bind("SerialStart") %>' Width="50px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Menu">
<ItemTemplate>
<asp:Label ID="tbMenu0" runat="server" Text='<%# Bind("CafeMenu") %>'
Width="80px" />
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList ID="ddlmenu0" runat="server" DataSourceID="DSMenu"
DataTextField="Cafe_Menu" DataValueField="Cafe_Menu" Width="80px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Description">
<ItemTemplate>
<asp:Label ID="lblDes0" runat="server" Text='<%# Bind("Description") %>'
Width="70px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbDes0" runat="server" Text='<%# Bind("Description") %>'
Width="70px" />
</EditItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Transaction">
<ItemTemplate>
<asp:Label ID="lblTrans0" runat="server" Text='<%# Bind("Transaction") %>'
Width="70px" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="tbTrans0" runat="server" Text='<%# Bind("Transaction") %>'
Width="70px" />
</EditItemTemplate>
</asp:TemplateField>
</Columns>
<PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#7C6F57" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:Coupon ManagementConnectionString30 %>"
SelectCommand="SELECT * FROM [CouponTransaction]"></asp:SqlDataSource>
</asp:Content>
|
|
|
|
|
there is no error the code u suggest but on run it not show gridview.
|
|
|
|
|
|
You code is missing <ContentTemplate> construct. Wrap every thing within your update panel in <ContentTemplate> . For example net out put should be something like
<updatepanel ------ ><br />
<ContentTemplate><br />
.................<br />
</ContentTemplate><br />
</updatepanel>
|
|
|
|
|
Hi all,
i have a issue.
i need to display alert Message before the page is redirect to another page.
1)alert Message
2)Response.Redirect("test.aspx")
Here, i have to use Response.Redirect complusory.
Please Help Me.
Thanks in Advance.
JohnDas
|
|
|
|
|
|
Alert is a client side operatoiin where as Response.Redirect is server side. You can't do both at same time because in your case you first need alert and then redirect. Soluton would be to out put some javascript that in turn do the desired task for you. For example try something like below in your ASP.NET code where you want this behaviour.
<codepage.registerclientscriptblock("alert-script", "alert('your="" alert="" here');window.location="http://yourdomain.xyz" ;");="">
|
|
|
|
|
can any one confirm that i want to implement passport based authentication in asp.net
and latest sdk found on microsoft website is 1 year old and only works for iis6
i am using iis7 is that obsolete or any other alternative way to implement this...
any help would be appriciated...
Government Dyal Singh College Lahore.
|
|
|
|
|
|
thanks for reply
yes i have seen these both articles already
first post is 6 years old and second one is related to iis 6 i want to implement it on iis7
or do you have any latest article related to this.. i have found SDK which is also 2,3 years old...
Government Dyal Singh College Lahore.
|
|
|
|
|
|
thanks this is what i was looking for..
Government Dyal Singh College Lahore.
|
|
|
|
|
what is Ajax?I want to use the technology in image control
|
|
|
|
|
ritasaumya wrote: what is Ajax?
It is Asynchronous JavaScript and XML.
ritasaumya wrote: I want to use the technology in image control
You need to clarify what you meant here.
|
|
|
|
|
Why do you want to use it, if you have no idea what it is ? Did you read the term on the internet and decide it would make you cooler ?
Don't use things you don't understand, and don't use things for the sake of them.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Thats useless info to him.
|
|
|
|
|
first have basic idea of ajax.go google....
|
|
|
|
|
|
ok - displaying a datagrid and using the ButtonColumn for the column. The text shows as a link and I want to control the display of the link. The gb is GridBody, gt is GridText and ac is AlignCenter. No matter what I play with in the CSS, it will not remove the link apparence in the datagrid. I have the .gt:link defined in the css, but no effect. Any ideas?
<asp:datagrid id="grdLibrary" CssClass="gbdr" Width="100%" AutoGenerateColumns="False"
AllowSorting="True" HorizontalAlign="Center" AllowPaging="True" PageSize="20" OnPageIndexChanged="grdLibrary_PageIndexChanged"
OnItemDataBound="grdLibrary_ItemDataBound" OnItemCommand="grdLibrary_ItemCommand" runat="server" >
<HeaderStyle CssClass="gh ght ac" />
<ItemStyle CssClass="gb gt ac" />
<AlternatingItemStyle CssClass="gba gt ac" />
<Columns>
<asp:ButtonColumn DataTextField="Title" HeaderText="Library" ButtonType="LinkButton" ItemStyle-Width="140px" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" />
|
|
|
|
|
What if you define CSS for all links on the page ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
a) how?
b) what is the ITEM I am looking for.
|
|
|
|
|