473,748 Members | 4,951 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Using ItemCreated for a Repeater in VB?

Hello - I am trying to create a repeater control that contains a
dropdownlist. A friend of mine sent me a sample in C#. I am trying to
duplicate the sample in VB. This is the C# code in the OnLoad event:

//bind the items to the repeater
this.repeater.D ataSource = items;
this.repeater.I temCreated += new
RepeaterItemEve ntHandler(repea ter_ItemDataBou nd);
this.repeater.D ataBind();

Attaching the RepeaterItemEve ntHandler to ItemCreated is giving me
problems. I want to use this in the OnLoad and not in the
OnItemCreated in the repeater tag. Any clue how one would write the
following line in VB:

this.repeater.I temCreated += new
RepeaterItemEve ntHandler(repea ter_ItemDataBou nd);

Thanks,
Jason

Mar 28 '06 #1
3 1800
AddHandler repeater.ItemCr eated, AddressOf repeater_ItemDa taBound

Mar 28 '06 #2
That was it! Thank you!

Mar 29 '06 #3
You are welcome.

Mar 29 '06 #4

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

Similar topics

3
1800
by: Jeremy Ames | last post by:
I am trying to use a datagrid to pull information from a database. I prefer to use latebinding to this. Well, I finally got my information to populate the datagrid, but the information came out in a table format. Is there a way that I can make the datagrid use list box or some other kind of grid? Perhaps I am using the wrong components. Someone please help.
1
1373
by: Lars Netzel | last post by:
Hi! I'm so confused right now.. I have a Page that load a datagrid with a a bunch of radiobuttons in three columns which are then checkes or uncheck in the ItemCreated.(it's supposed to be a permission setting for different things in my application) There is a save button on the page to save the permissions set in the grid. The BindGrid() is called if it is NOT a postback in the PageLoad. Then, in debugging, when the User presses the...
9
2331
by: Manuel | last post by:
I have a Datagrid with 9 elements. The problem is that when I sort the grid by a column, it present more columns than there are. This is my code for the ItemCreated event: Private pNo As Integer = 0 Private Sub grd_ItemCreated(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) Handles grd.ItemCreated
4
15311
by: Dennis E. Jones, Jr. | last post by:
I'm creating a dynamic control for each row in a REPEATER based on database values. ItemDataBound creates the control for the initial load (not postback), but I cannot get the control recreated when command to save data (postback) occurs. How do I get the values for this dynamic control on postback and place the control back into its original position? Sample Uses Pubs Database for SQL Server: Imports System.Data.SqlClient
2
3481
by: Philippe Camus | last post by:
I didn't find any documentation about this behaviour. On postbacks the Repeater ItemCreated event is fired before Page_Load event It occurs for each item with empty RepeaterItemEventArgs.Item.DataItem. Does anybody know more about this strange behaviour? Thanks Philippe
0
1090
by: Jason James | last post by:
Guys, I have a webform that uses a datalist control to display a series of thumbnail images. Each image is is also associated with two dropdown lists. One contains the quantity of images required and the other contains the size of the image that is requried. The qty dropdown list is populated as follows: dlQty = CType(e.Item.FindControl("dlQty"), DropDownList)
3
9170
by: Brian | last post by:
Using external XML, I'm trying to build a quiz, but I can't seem to specify the DataSource for the RadioButtonList within a Repeater ItemTemplate. I've tried a number of approaches, but I haven't really had any success. I'm pretty sure I should be casting my XPathSelect() call to something so I can get at its attributes. This seems like it should be easy, and maybe I'm missing something obvious. Does anyone have any ideas? Here is the...
0
2572
by: Eugene Anthony | last post by:
The problem with my coding is that despite removing the records stored in the array list, the rptPages repeater control is still visible. The rptPages repeater control displayes the navigation link (1,2,3 so on). The code can be found in SubscriptionCart.aspx.cs. Default.aspx ------------
1
7132
by: jazzart | last post by:
Hi there, I'm fairly new to programming with Asp.Net 2.0 so I'm finding myself regularly fumbling around in the dark a bit, so to speak. I'm currently using Visual Web Developer and have been following the www.asp.net data access tutorials to create a DAL and BLL to connect my web site (a simple real estate property search web site) to my database (Sql Express 2005).
0
8989
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9537
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9243
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8241
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6795
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4599
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4869
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3309
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 we have to send another system
2
2780
muto222
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.