Wrox Programmer Forums
|
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 25th, 2010, 02:34 AM
Authorized User
 
Join Date: Apr 2010
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default gridview databind in webmethod

hi every one,

I am using modelpopupextender.this will be shown on keypress event (F2 press) using javascript. This modelpopup,targeted to panel,having a gridview where i bind data during the form view databound event.But the problem is i need to rebind the gridview when F2 is pressed,untill formview mode is not changed.This rebind is to be done bcoz, when a new record is entered in masters,it is not been shown in the gridview as post back is not happening. So i want to try it by web method. But in static webmethod,it is unable to find the gridview control. So,can anyone suggest,or send the related code to solve the problem. I hope u understood the problem.

[WebMethod(EnableSession = true)]
public static int fun()
{
//here i am unable to find the control
}

is this the right method to do?

Thanks
 
Old May 25th, 2010, 03:10 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Duplicate. Please see here: http://p2p.wrox.com/asp-net-2-0-professional/79539-gridviewbind-using-javascript-webmethod.html

Can you please not post duplicate posts?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!





Similar Threads
Thread Thread Starter Forum Replies Last Post
GridView Databind issue julius ASP.NET 2.0 Basics 1 March 31st, 2009 11:05 PM
Gridview, databind retrieving value from database julius ASP.NET 2.0 Basics 1 March 23rd, 2009 11:33 PM
Databind a gridview question. chobo2 ASP.NET 3.5 Basics 4 March 8th, 2009 04:38 PM
DataView will not DataBind with a GridView?! jason.l ASP.NET 2.0 Basics 0 October 13th, 2006 10:01 PM
Gridview DataBind to DataTable not showing changes wirerider ASP.NET 2.0 Basics 1 March 4th, 2006 08:59 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.