473,473 Members | 1,583 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Web User Control - calls to server side code

I know, of course that client side stuff cant call server code
directly. What I am doing is putting in a basic LeftHand menu bar
using a user control that contains a datagrid composed of linkbutton
controls. I am populating this either manually (one item at a time
programatically) or via a DataBind to a database table.

How do I link the items to server side code methods? If I had created
the link buttons manually on the page, they would be tied code with
even handlers on their click events dynamically. Im wondering how I
would go about defining this event handler knowing....

A. Visible text for menu item.
B. The name of the method in code that should be called as a result of
clicking on the menu item.

I want to be able to generate all the code to take care of the menu as
I build it, or when I call Databind.

TIA
Nov 18 '05 #1
1 1713
the datagrid among other controls supports templates where you can specify
an event handler that you have and pass it values if you want like say the
value of column 2 in the current row in the dataset that you are binding the
datagrid to.

"Dan Brussee" <db******@nc.rr.com> wrote in message
news:so********************************@4ax.com...
I know, of course that client side stuff cant call server code
directly. What I am doing is putting in a basic LeftHand menu bar
using a user control that contains a datagrid composed of linkbutton
controls. I am populating this either manually (one item at a time
programatically) or via a DataBind to a database table.

How do I link the items to server side code methods? If I had created
the link buttons manually on the page, they would be tied code with
even handlers on their click events dynamically. Im wondering how I
would go about defining this event handler knowing....

A. Visible text for menu item.
B. The name of the method in code that should be called as a result of
clicking on the menu item.

I want to be able to generate all the code to take care of the menu as
I build it, or when I call Databind.

TIA

Nov 18 '05 #2

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

Similar topics

2
by: Pham Nguyen | last post by:
Has anyone seen an example of a textbox server control that has built-in client-side validation? I'd like to build a server control that extends the System.Web.UI.WebControls.TextBox class to allow...
7
by: moondaddy | last post by:
I have a user control being used instead of a frame page. when the user clicks on a menu item I need to send the ID (integer value) of that menu as a parameter in the postback of the user control...
1
by: Dan Brussee | last post by:
I know, of course that client side stuff cant call server code directly. What I am doing is putting in a basic LeftHand menu bar using a user control that contains a datagrid composed of linkbutton...
4
by: Barb | last post by:
I have a user control as my Save button for my page. When the Save button is clicked, I want some client-side validation to take place from a javascript function in the page, and then I'd like the...
3
by: Ant | last post by:
I'm building a Web user control that has several public functions. Can I fire them from the client side? for example Javascript and an HTML button
9
by: Charts | last post by:
I use VS2005 to build a asp.net 2.0 project. I want to be able to click a button on the page and have a dialog window appear where I can navigate the folders to get hold of a file path to load...
4
by: tshad | last post by:
Is there a way for a User Control to access an object (such as label or textbox) on the .aspx page that calls it? For example: x.aspx ************************************** .... Sub...
0
by: Steven Cheng [MSFT] | last post by:
Hi Nick, From the description in your first message, I think what you want to do the let the webservice server-side proactively notify the webservice client for some changing, correct? I'm...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.