I'm a bit confused about something. I have an aspx page populated
with dynamic controls; textboxes, labels, radios and so on. On the
page is a Yes/No radio combination and 3 textboxes. The textboxes are
visible. If you click the No radio, the textboxes should disappear.
In my code, I'm setting the textbox's Visible property to false.
What happens is, when you click the No radio, the textboxes do
disappear. But I'm left with a blank space on the page equal to the
area the textboxes took up. I took the source of the resultant page
and copied out thie HTML into Dreamweaver to try and see where the
problem is. Well, the textboxes are still there. I assume there's
session data missing that's there when the page is actually generated
that hides the textbox but in essence, it doesn't really disappear.
So I start with this:
Heading
Radios Yes/No
Textbox
Textbox
Textbox
But when no is clicked (postback is performed that sets textboxes
visible to false ) I get:
Heading
Radios Yes/No (No selected)
Blank space
Blank space
Blank space
How do I get this space to disappear?
Thanks! 3 1182
have you tried enclosing the controlls in another control such as a tablecell
or a panel and then setting that to visible=false ?
"Fred Flintstone" wrote: I'm a bit confused about something. I have an aspx page populated with dynamic controls; textboxes, labels, radios and so on. On the page is a Yes/No radio combination and 3 textboxes. The textboxes are visible. If you click the No radio, the textboxes should disappear. In my code, I'm setting the textbox's Visible property to false.
What happens is, when you click the No radio, the textboxes do disappear. But I'm left with a blank space on the page equal to the area the textboxes took up. I took the source of the resultant page and copied out thie HTML into Dreamweaver to try and see where the problem is. Well, the textboxes are still there. I assume there's session data missing that's there when the page is actually generated that hides the textbox but in essence, it doesn't really disappear.
So I start with this:
Heading Radios Yes/No Textbox Textbox Textbox
But when no is clicked (postback is performed that sets textboxes visible to false ) I get:
Heading Radios Yes/No (No selected) Blank space Blank space Blank space
How do I get this space to disappear?
Thanks!
That's a thought, I'll see what I can do with that, thanks.
I should also point out that this behavior only occurs with text
boxes. If they were checkboxes, labels, literalcontrols or a
different radio set, the controls and the space they occupy disappear
properly.
On Thu, 23 Mar 2006 08:35:36 -0800, clickon
<cl*****@discussions.microsoft.com> wrote: have you tried enclosing the controlls in another control such as a tablecell or a panel and then setting that to visible=false ?
"Fred Flintstone" wrote:
I'm a bit confused about something. I have an aspx page populated with dynamic controls; textboxes, labels, radios and so on. On the page is a Yes/No radio combination and 3 textboxes. The textboxes are visible. If you click the No radio, the textboxes should disappear. In my code, I'm setting the textbox's Visible property to false.
What happens is, when you click the No radio, the textboxes do disappear. But I'm left with a blank space on the page equal to the area the textboxes took up. I took the source of the resultant page and copied out thie HTML into Dreamweaver to try and see where the problem is. Well, the textboxes are still there. I assume there's session data missing that's there when the page is actually generated that hides the textbox but in essence, it doesn't really disappear.
So I start with this:
Heading Radios Yes/No Textbox Textbox Textbox
But when no is clicked (postback is performed that sets textboxes visible to false ) I get:
Heading Radios Yes/No (No selected) Blank space Blank space Blank space
How do I get this space to disappear?
Thanks!
hi
I think u should use javascript in this
What u can u go to html page of aspx page and in textboxes
style="DISPLAY:none"
and then u use javascript that if no is selected then textboxes should
not be displayed and when yes is selected then textboxes should be
displayed.I hope this will solve ur problem .If not then mail me at kh**************@indiatimes.com and i will send full code to u
bye
varun
Fred Flintstone wrote: I'm a bit confused about something. I have an aspx page populated with dynamic controls; textboxes, labels, radios and so on. On the page is a Yes/No radio combination and 3 textboxes. The textboxes are visible. If you click the No radio, the textboxes should disappear. In my code, I'm setting the textbox's Visible property to false.
What happens is, when you click the No radio, the textboxes do disappear. But I'm left with a blank space on the page equal to the area the textboxes took up. I took the source of the resultant page and copied out thie HTML into Dreamweaver to try and see where the problem is. Well, the textboxes are still there. I assume there's session data missing that's there when the page is actually generated that hides the textbox but in essence, it doesn't really disappear.
So I start with this:
Heading Radios Yes/No Textbox Textbox Textbox
But when no is clicked (postback is performed that sets textboxes visible to false ) I get:
Heading Radios Yes/No (No selected) Blank space Blank space Blank space
How do I get this space to disappear?
Thanks! This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: VSK |
last post by:
Hi all,
In our ASP.NET web application we have to enable or disable features in each
ASP.NET page based on role assigned to user.
Ex: if user who logs in is superisor then he can change...
|
by: Peter Jackson |
last post by:
I'm using v2 of the UIP App. Block. I've created all my .aspx pages, all of which contain .ascx user controls. The .ascx user controls provide the standard server controls (i.e., LinkButtons, etc.)...
|
by: Milsnips |
last post by:
hi there,
i have a strange problem. I want to programatically loop through each
control on a page, but am having issues.
my test example:
1. header.ascx - the ascx control finds all the...
|
by: antonyliu2002 |
last post by:
I want to create session objects for all web controls in a page. Right
now, I am doing it in a dumb way like this (for example):
Session("Session1") = ctrl1.Text
Session("Session2") =...
|
by: swesorick |
last post by:
I would like 95% of my site to have the viewstate disabled, in order to
reduce the size of my pages. However, there are about 5% of the pages
on my site that will require viewstate.
Is there...
|
by: EagleRed |
last post by:
I am writing an ASP.NET 2.0 application that uses master pages. I have some
pages that must not be cached on the client. In ASP.NET 1.1 I achieved this
using metatags:
<meta...
|
by: SAL |
last post by:
Hopefully someone will have a clue as to what is happening here. In our
office, we have both ColdFusion and ASP.NET applications. One of our new
developers has been installing ColdFusion 8 on the...
|
by: DamienS |
last post by:
Hi,
I'm wondering if there's a way to prevent ASP.Net from rebasing the
URLs/Paths in my Images.
My website is using a reasonably complex system to perform skinning
(custom code combined with...
|
by: jehugaleahsa |
last post by:
Hello:
I am sure this question comes up a lot. I need to disable the controls
on my Windows forms so that when the BindingSource is empty some the
controls bound to it will be disabled.
This...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
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: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
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: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
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,...
| |