I am developing an app in ASP 3.0
I want to create a table with some text boxes at run time, so that when i
press a command button on the page, some rows and columns should be created
on the page.
Please help me on how to create these html table tags at run time. If anyone
can point to a sample, it would be good.
Thanks a lot! 3 8978
Hi Anil,
A ver simple sample from buttons and a calender at run time I once made.
I hope this helps?
Cor
\\\It needs a "Panel1" on a page.
Private Sub Page_Load(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles MyBase.Load
Dim mybutton(31) As Button
Dim i As Integer
For i = 0 To New Date().DaysInMonth _
(New Date().Year, New Date().Month) - 1
mybutton(i) = New Button
mybutton(i).BackColor = Drawing.Color.White
mybutton(i).Text = (i + 1).ToString
mybutton(i).Width = New Unit(30)
Me.Panel1.Controls.Add(mybutton(i))
AddHandler mybutton(i).Click, AddressOf mybutton_Click
If (i + 1) Mod 5 = 0 Then
Me.Panel1.Controls.Add(New LiteralControl("<BR>"))
End If
Next
End Sub
Private Sub mybutton_Click _
(ByVal sender As Object, ByVal e As System.EventArgs)
Dim mylabel As New Label
Me.Panel1.Controls.Add(New LiteralControl("<BR><BR>"))
Me.Panel1.Controls.Add(mylabel)
mylabel.Text = "The day is: " & DirectCast(sender, Button).Text
End Sub
///
Thanks Cor. But I need it through HTML tags.
I am making an ASP page with coding in InterDev!!
Please give me some link that has this.
Thanks a lot!!
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl... Hi Anil,
A ver simple sample from buttons and a calender at run time I once made. I hope this helps?
Cor
\\\It needs a "Panel1" on a page. Private Sub Page_Load(ByVal sender As System.Object, _ ByVal e As System.EventArgs) Handles MyBase.Load Dim mybutton(31) As Button Dim i As Integer For i = 0 To New Date().DaysInMonth _ (New Date().Year, New Date().Month) - 1 mybutton(i) = New Button mybutton(i).BackColor = Drawing.Color.White mybutton(i).Text = (i + 1).ToString mybutton(i).Width = New Unit(30) Me.Panel1.Controls.Add(mybutton(i)) AddHandler mybutton(i).Click, AddressOf mybutton_Click If (i + 1) Mod 5 = 0 Then Me.Panel1.Controls.Add(New LiteralControl("<BR>")) End If Next End Sub Private Sub mybutton_Click _ (ByVal sender As Object, ByVal e As System.EventArgs) Dim mylabel As New Label Me.Panel1.Controls.Add(New LiteralControl("<BR><BR>")) Me.Panel1.Controls.Add(mylabel) mylabel.Text = "The day is: " & DirectCast(sender, Button).Text End Sub ///
Hi Anil,
That you can do using javascript and the "document.write" however that has
nothing to do with dotnet.
I would look for that if I was you in an Interdev and/or ASP newsgroup.
Cor This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Nick |
last post by:
Loop to create an array from a dynamic form.
I'm having trouble with an application, and I'll try to explain it as
clearly as possible:
1. I have a form with two fields, say Apples and...
|
by: Wolfgang Kreuzer |
last post by:
Hello all,
I have two tables - Projects and ProjectStruct
Table Projects contains master records of the projects, ProjectStruct
allows to define a project herarchie and contains the fields...
|
by: Kiyomi |
last post by:
Hello,
I create a Table1 dynamically at run time, and at the same time, I would
like to create LinkButton controls, also dynamically, and insert them into
each line in my Table1. I would...
|
by: poohnie08 |
last post by:
i have a excel spreadsheet showing staff name, date,work hour, ot
hour, slot1, slot2, slot3, slot4 and others). The "()" will keep
repeating from day 1 until end of month.
eg in excel spreadsheet,...
|
by: skgolden |
last post by:
My husband and I own a small temporary labor company and deal with 4
major clients (A,B,C & D), each of which has about 2 dozen units in
our tristate area that we deal with (ie, Company A, units...
|
by: flkeyman |
last post by:
Work in legal office. Trying to create solid designed database
structure. This is list of tables w/fields and primary keys. Any
comments/advice greatly appreciated.
tbl-Defendants
CaseNumber...
|
by: Bob Achgill |
last post by:
I would like to use the timestamp on files to manage the
currency of support files for my VB windows application.
In this case I would only put the timestamp of the file
in the management database...
|
by: Jimakos Bilakis |
last post by:
Hi everyone!
I want to create a function that it will take as parameters a table
(float), an integer (the number of Table's rows) and it will re-arrange
the elements in the table from the...
|
by: etuncer |
last post by:
Hello All,
I have Access 2003, and am trying to build a database for my small
company. I want to be able to create a word document based on the data
entered through a form. the real question is...
|
by: Solunac |
last post by:
Hi, everyone, I am new here ...
I have a problem to create a after-trigger (update).
Example tables:
CREATE TABLE R
(
log_num SMALLINT NOT NULL,
int_num SMALLINT NOT NULL,
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
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,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
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,...
|
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...
|
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...
|
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,...
| |