all groups > asp.net building controls > november 2003
Filter by week: 1 2 3 4 5
Last one for now... How do I convert this C# code to VB.NET
Posted by Wayne at 11/29/2003 6:24:11 PM
C#
if (s is MyPanelStyle) {
....
}
I thought this would work but it is not...
If s is MyStyles.Button Then
....
End If
....but I get a blue squiggly 'Button' is type in 'MyStyles' and cannot be
used as an expression.
... more >>
How do I convert this... from C# to VB.NET
Posted by Wayne at 11/29/2003 4:45:02 PM
public MyPanelStyle(StateBag bag) : base(bag) {
}
These do NOT work, what I think the conversion should be...
Sub New(ByVal bag As StateBag)
Inherits CType(bag, base)
End Sub
However, I get a blue squiggly under Inherits "Statement is... more >>
Calendar Controls don't fire events
Posted by mark NO[at]SPAM corporatedigital.com at 11/29/2003 12:22:38 PM
Good afternoon all.
I am creating a usercontrol (*.ascx) with a Calendar control on it.
In the Calendar's DayRender event I'm dynamically adding ImageButton
controls to cells on the calendar. For each of these image button I'm
hooking up a click event as so:
imgButton.Click += new ImageClic... more >>
Changing color in a button
Posted by me at 11/28/2003 3:10:55 PM
Hello,
I have a question about how too change the background of a command button
once it has been click from aliceblue to azure.
TIA,
Aaron
... more >>
Error Setting user control property at web form
Posted by Amir Eshterayeh at 11/26/2003 7:30:01 PM
Dear Friends
Hope things goes well to you. I have this problem. Would you please give me
your solution?
I want to change a property that I define on my user control in my web form
that contains that user control.
but when I want to set the property of user control at my web form, got this
er... more >>
absolutePositioning attribute of Custom webcontrol
Posted by Alessandro Zifiglio at 11/26/2003 5:34:56 PM
Hi, does anybody know if its possible to code for the absolute positioning.
I have noticed that vs.net applies these attributes to any webcontrol. This
is how you are able to move your control around in the designer.
I'd like to include the left and top as properties of my custom control and
hav... more >>
JavaScript Src attrubute in ascx
Posted by New User at 11/26/2003 7:57:46 AM
I have a System.Web.UI.UserControl as custom control and
I have a javascript block for user control. The problem
is I want to bring src attribute from outside as property
or other method.
e.g <script language="JavaScript"
src="Scripts/filename.js"></script>
When I register this contro... more >>
Dynamic Changing Properties
Posted by Shawn B. at 11/26/2003 7:46:46 AM
Greetings,
Suppose I have a control that by default, all the properties and text
rendered is English. If supported, and the user changes to say, arabic, is
it possible for me to change the control enumerations also in the property
editor so that it looks Arabic?
I'd think not. Perhaps I h... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Getting PostBack Data from DropDownList Control
Posted by Lance at 11/25/2003 9:25:46 PM
Hi Guys.
Im trying to catch the postback event for a control that
Inherits from the System.Web.UI.Webcontrols.DropDownList
Ive used the code below for controls inherited from
System.Web.UI.Controls
But it dosnt work when I inherit from dropdownlist.
Any ideas?
Imports System
Impo... more >>
User Control properties
Posted by Netvision Mail at 11/25/2003 8:11:08 PM
Hi all,
I'm a total newbie, so this might be stupid...
Anyway, I've created an expanding tree of categories control, based on
DataList.
It works almost fine, but I can't make it return the value of the last
category clicked.
To be more specific, it does return it, but only the second time I cl... more >>
Events Handling Order
Posted by IgorRubinovich NO[at]SPAM yahoo.com at 11/25/2003 5:04:00 PM
Hi all,
I'm a total newbie, so this might be stupid...
Anyway, I've created an expanding tree of categories control, based on
DataList.
It works almost fine, but I can't make it return the value of the last
category clicked.
To be more specific, it does return it, but only the second time I cl... more >>
Testing existance of a datagrid control on a webform
Posted by Iain Porter at 11/25/2003 3:43:36 PM
Hi all,
I have a usercontrol (a textbox with dropdown calendar that fills the
textbox with the selected date) that I implement in a datagrid in a webform.
On first loading the page, the datagrid's visibility is set to 'false', and
so the UC depCal is not rendered on the page. Hence the followin... more >>
LoadViewState does not fire on a postback event
Posted by Jean Erasmus at 11/25/2003 1:06:44 PM
Hi there,
I need some help please. I have created a composite control that have a
collection of items associated with it. Now I want to save this to the view
state of the control, but the LoadViewState method does not get called so I
can get the collection out of the view state.
Does anybod... more >>
div element taking up space
Posted by dave at 11/25/2003 9:42:24 AM
I am hiding the contents of a table cell with
display:none like the following:
When I do this and while hidden the row still takes up
some vertical space. How can I best use div elements to
hide table row while not taking up and vertical space?
thx
<TR>
<TD><DIV id="div1"
style... more >>
Handle exception in ProcessPostData
Posted by Mono at 11/25/2003 8:55:44 AM
Is there any way to catch (and handle) exceptions in the ProcessPostData or
ProcessPostDataSecondTry methods?
p.s.
From custom web control.
Zarko
... more >>
embeding Javascript src attribute in User control
Posted by New Asp.net developer at 11/25/2003 7:34:48 AM
I have a System.Web.UI.UserControl as custom control. I
have a javascript block for user control. The problem is
I want to bring src attribute from outside as property or
other method.
e.g <script language="JavaScript"
src="Scripts/filename.js"></script>
When I register this control (... more >>
CreateChildControls not being called
Posted by Colin Young at 11/24/2003 1:59:26 PM
Has anybody ever seen a situation in a custom control where
CreateChildControls is not being called? I've set a break point in the
method and it is never hit (in addition, none of the controls that are
supposed to be created are not being created so I'm reasonably certain it
isn't just a problem... more >>
Inverted Controls?
Posted by Eddie B. at 11/24/2003 12:04:58 PM
Is there a way to invert a control like text box? I am trying to make an
interface that will look like a tablet if you turn a laptop to the side.
This will enable the users in the company to use the touchscreen laptops
that they have like they use tablets on other areas of our company. It is a
... more >>
Custom Composite Control, child User-controls loosing view state
Posted by Mike J. at 11/24/2003 9:12:14 AM
I've created composite custom control which dynamically creates and arranges
it's child controls based on some xml data. Beside the simple web form
controls there is an option of loading user-controls (UC) at run-time. Child
controls are created/loaded/initialized in overridden CreateChildControl... more >>
Adding dynamically user control (ASCX) into asp.net page and handling OnClick event
Posted by francois.verdon NO[at]SPAM videotron.ca at 11/23/2003 9:11:46 PM
Hi,
I've been reading a lot's of Q&A on user controls but none seem to
answer my question. Here it is. I need to add dynamically a user
control, in a htmltablecell, in an asp.net page (done in VB). This is
the way, that I thought, was the wright way doing it:
Dim oTable As New HtmlTable()
... more >>
Displaying template content in vs.net designer
Posted by Alessandro Zifiglio at 11/23/2003 6:27:45 PM
hi, I'm trying to display the content within my "templated databound custom
controls" templates at design time, in the vs.net designer. I'm able to get
the cotents of my template using the GetTextFromTemplate() method. This
returns all controls within my template as a string, for example if i had... more >>
I'm trying to convert this from C# to VB.NET any ideas?
Posted by Wayne at 11/22/2003 10:32:59 PM
public event EventHandler Logon {
add {
Events.AddHandler(EventLogon, value);
}
remove {
Events.RemoveHandler(EventLogon, value);
}
}
... more >>
Client-Side Script for CheckBox Web Control
Posted by Mickie at 11/22/2003 9:15:53 PM
I'm trying to create a server Web control that renders as a checkbox that
has an OnClick event associated with it. I've created a short proof of
concept to simply attach an alert message when the checkbox is clicked. The
problem is that the override is being ignored and the OnClick event is nev... more >>
Visual Studio locks assemblies for ASP.NET project.
Posted by Rob Mayo at 11/21/2003 10:29:47 AM
I am working in an environment with 4 developers. 2 groups of 2 people
working on the same server on the same web project with no version control
management on the web server.
Programmers A & B servername/project1
Programmers C & D servername/project2
All programmers have solutions that ha... more >>
Problem with adding UserControls programtic in the OnPreRender event and still keep the UC viewState
Posted by Flare at 11/21/2003 1:17:33 AM
(ASP.NET 1.1)
Hi
I have a problem with my ViewStates in a userControl. The problem is that
the ViewState is not "writte" og changed if you like after editing in my
case a textbox.
This is the code I use to add the User controll
Control Component1 = null;
Component1 = LoadControl("MyUC.a... more >>
server control: recreating controls after roundtrip
Posted by J.Hero at 11/20/2003 10:38:41 AM
How can i recreate controls which were added to the control collection on
runtime after a roundtrip in a server control with no aspx/ascx files? There
is no page object in which i could ask for the postback status.
Any ideas?
Thanks for your help.
J.Hero
... more >>
CssClass property not working
Posted by jdaley NO[at]SPAM data-tronics.com at 11/19/2003 11:07:48 AM
In a composite control, here's my CreateChildControls Sub-Procedure...
Protected Overrides Sub CreateChildControls()
Me.Controls.Clear()
_txtDate = New TextBox
_txtDate.ID = _txtDate.ClientID
_txtDate.CssClass = "FormElementEnabled"
_txtDate.Text =... more >>
Custom Control Font Property
Posted by samulski NO[at]SPAM hotmail.com at 11/19/2003 5:38:00 AM
Dear readers,
Have a web custom control going but can't seem to manage this easy
thing.
The custom control inherits from System.Web.UI.WebControls.WebControl.
The custom control consists of 2 images and a label. The Custom
Control has from default a Font property. How can I use the default
... more >>
Insufficient state to deserialize the object
Posted by mcpollo NO[at]SPAM terra.es at 11/19/2003 2:25:41 AM
Hello,
In our development team we want to load into the VS toolbar a control
library from a network drive.
When we load it to the toolbox we get an error from the IDE:
"Insufficient state to deserialize the object. More Information is
needed"
If we do the same from a local copy of contro... more >>
Web Control Libary - innertext between webcontrol tag
Posted by Darvin Zuch at 11/18/2003 6:19:45 PM
I'm replacing my <a href="default.aspx">ClickMe</a> with a
<ptc:a href="default.aspx">ClickMe</ptc:a>
How do I create code within my web custom control to capture my "ClickMe"
text?
Darvin Zuch
... more >>
How to Change hierarchy of controls?
Posted by Nenad Prekupec at 11/18/2003 2:48:16 PM
Hi,
I'm writing custom control inherited from system.web.ui.webcontrols.panel. I
want that MyPanel make some modifications in rendering panel with its child
controls and add some button to render (and raise events) on that panel. I
have created control and it works fine BUT....
After post bac... more >>
custom controls
Posted by vijaya at 11/18/2003 3:59:37 AM
I'm a learner of ASP.Net.
I want to try out a custom control of my own.
I'm not getting a clear of how to add my own properties to
the control apart from the common properties like text,
color, font etc..
How should I design a html tag with a complete new
property?
I need good mate... more >>
binding data to header
Posted by vijaya at 11/18/2003 3:54:34 AM
Can we bind data to textbox in a headertemplate in a
template column of a datagrid?
I've tried with text box and table. But I couldn't
succeeed.
If aanyone has tried it,please help me out.Please give
some code snippets.
... more >>
Complex properties (Button) not persisting in webcontrol
Posted by p_j_downes NO[at]SPAM hotmail.com at 11/18/2003 2:42:30 AM
This seems to be a common issue and one that I have not found a
solution to. What I want to do is theoreticly simple. I have tried
creating webcontrols with simple properties string e.t.c and all work
fine. I am now in the process if trying to create a webcontrol that
contains more complex prope... more >>
Refer to a custom property of a dynamically loaded user control
Posted by Bryan Holland at 11/17/2003 5:13:45 PM
I have an app where I dynamically load a user control based on the type of
data it is rendering. There are some standard custom properties that I want
to access.
How do I refer to a custom property of a dynamically loaded user control?
Thanks
B
... more >>
debug a user control
Posted by rua17 at 11/17/2003 5:08:17 PM
I created a control that inherits from button
What should I do in order to debug the code that I just created. I built the
control with debug info, and I put some break points but, when I execute the
button from a form, The code doesn't start the debugger.
Any Ideas??
... more >>
Drawing Control
Posted by Don Miller at 11/17/2003 2:36:23 PM
I am looking for a web based drawing control but have had no luck finding
one. I want something that is similar to Visio where there is a palette of
objects that get dragged to a drawing surface or panel. It needs to have the
same basic functionality of Visio like drag and drop, connecting of obj... more >>
Unable to generate code for a value of type...
Posted by Chris Bower at 11/17/2003 9:38:32 AM
Ok, I've got a bunch of derived controls that all have a property Rights of
type Rights (Rights is an Enumerator). I wrote a custom TypeConverter so
that I can use comma separated values in design-time. The TypeConverter
works great in design-time. It converts to and from just fine... However,
w... more >>
a project for control??
Posted by rua17 at 11/17/2003 8:58:42 AM
I want to create a library of my custom controls, can I create a lot of
controls in one project or I need one project per control?
... more >>
Adding a Register directive to an aspx page programmatically
Posted by Arnaud PICHERY at 11/16/2003 11:40:57 PM
Hi !
I am reposting the following question as it went under another topic (don't
know exactly why)
I have a design-time problem that puzzle me...
I am building a WebControls library and one of the control inherits from
Chart which is located in the DundasWebChart WebControls library.
When ... more >>
DataGrid - How to scroll
Posted by sumit acharya at 11/15/2003 12:33:44 AM
Hi,
I want to make a datagrid scrollable in asp.Net. The datagrid should be
scrollable but not its header means first row,,
I know that div can be used but how to nake header of the datagrid
non-scrollable and rest as scrollable?
Please suggest!!
*** Sent via Developersdex http://www.dev... more >>
Can client-side script be included in a user control (ascx)?
Posted by msdn NO[at]SPAM SoftwareIntensive.com at 11/14/2003 3:29:23 PM
I am creating a simple usercontrol (.ascx). There is some client-side
functionality I would like it to have. I tried adding in a Script
element, but that did not work. Do I have a bug or is it simply that
client-side script cannot be compiled into a user control? Thanks.
--Isaac
... more >>
how to share server control assembly among multiple programer enviroment?
Posted by Nenad Prekupec at 11/14/2003 1:32:29 PM
Is there a way to share server control dll (control is still under
development) in toolbox without having to copy that dll to client computers?
I have a multiple programers enviroment, the code for Web .net project is on
one server and under source safe control. In this project we are using
co... more >>
Dropdownlist as hyperlink!!!
Posted by ashoo at 11/14/2003 12:24:26 PM
Guys!
I am trying to use a dropdownlist click event in my header
page to link to my main page in a frameset type of form.
I try to link to my main page with a hyperlink control.It
works fine. But I would like to use the click event of my
dropdownlist to do the samething. so I thought if co... more >>
Using Global variable in .ascx file
Posted by srinivas.reddy NO[at]SPAM ebusinessware.com at 11/14/2003 6:59:11 AM
How can I use a Global variable in .ascx page. I have created a menu
control and registered it in my .ascx file. I want to use the global
variable in this page for hardcoded path. The code snippet is like:
<%@ Control CodeBehind="MenuControl.ascx.cs" Language="c#"
AutoEventWireup="false" Inher... more >>
Is this a bug or what?
Posted by c_zachariadis NO[at]SPAM hotmail.com at 11/13/2003 1:57:06 PM
does webform control equal to asp.net control?
Posted by thxBruin at 11/12/2003 11:47:41 AM
If no, could you show me the differentia?
thanks,
ThxBruin
... more >>
Can we bind data to textbox in a headertemplate of a datagrid
Posted by Vijaya at 11/12/2003 3:55:59 AM
Can we bind data to textbox in a headertemplate in a
template column of a datagrid?
If so please give some code snippets.
Thank you... more >>
Rendering non-composit Control
Posted by MartinL at 11/12/2003 2:09:50 AM
Hello NG
I'm a newbie with programming controls and
this seems to me a very easy question:
I had create a non composit control.
Inherit from Textbox
Now I want only to write a text over the textbox and a
picture after the textbox.
The control compiled successful and I add the control to m... more >>
Dynamic User Controls Event Handling
Posted by Majeti at 11/11/2003 5:04:55 AM
In my web form to the place holder i'm loading different
User Controls depends on some conditions
for the user control which is loaded first time to the
place holder is able to fire event.
but Events are not firing for the User control which is
dynamically loaded second time in place fir... more >>
|