all groups > asp.net webcontrols > october 2006
Filter by week: 1 2 3 4 5
Binding a single object to a control
Posted by paul.hester NO[at]SPAM gmail.com at 10/31/2006 8:26:22 PM
Hi all,
This probably sounds like a stupid question, but what is generally the
recommended way to display a business object in the aspx file for an
object fetched in the code behind file?
Normally I've been fetching the object in the code behind and exposing
the object's properties that I n... more >>
Radiobuttonlist (a custom control) selectedindexchanged event not firing in User Control
Posted by Martin Frank at 10/31/2006 4:58:14 PM
I created a custom control so I could control how my RadioButtonList was
rendered. Adding an instance of the custom control to a form seems to
work no problem. However if I add an instance to a User Control the
SelectedIndexChanged event does not seem to fire.
Here is code for the custo... more >>
Data Grid Printing
Posted by gurvar at 10/31/2006 1:55:01 PM
Hi,
When I print a data grid, only the first page shows the grids and not the
succeeding pages. If there 3 pages, only Page 1 shows the grid lines for the
data displayed. The rest of pages don't show grids to the displayed data.
Any feed back will be very much appreciated.
Thanks... more >>
Validator bug
Posted by Abraham Andres Luna at 10/31/2006 8:50:32 AM
shouldn't this code work?
<%@ Page Language="C#" MasterPageFile="~/secure/admin/adminpage.master"
Title="Validator Test Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cphNavSub" Runat="Server">
<IS:ISBaseReqValidator runat="server" ControlToValidate="tbCUSID"
ErrorMessage="Cu... more >>
ControlCollection.Remove bug
Posted by Abraham Andres Luna at 10/30/2006 2:57:58 PM
hello everyone,
this code only removes the first HtmlMeta control even though i loop through
all of the controls:
<%@ Page Language="C#" %>
<script runat="server">
void Page_Load(Object Sender, EventArgs E)
{
foreach (Control ctl in Page.Header.Controls)
if (ctl.GetType().... more >>
operations on string
Posted by mamin NO[at]SPAM o2.pl at 10/30/2006 7:20:18 AM
Hi all,
Anyone know some smart way to get two first substrings from string, in
example how to get string
"aaaa bbbb" from string "aaaa bbbb cccc ddddddd"?
... more >>
how to show dialogbox when click on datagrid template column?
Posted by chandu at 10/30/2006 12:00:00 AM
hai,
i am using datagrid template column ,it is text box column.
if i put any thing in that cell and when i leave that cell i need to show a
dialog box with that enterd string.
please can any one give answer as early as possible.
... more >>
HyperLinkField and OnRowDataBound
Posted by David Thielen at 10/29/2006 9:43:04 PM
Hi;
How can I access a HyperLinkField in a GridView in the OnRowDataBound call?
Looking at what is passed in it looks like at that point all that exists is
the HyperLink control that HyperLinkField creates.
Also very weird that there is no ID="name" attribute for HyperLinkField.
Any ide... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
visibly disable img link
Posted by David Thielen at 10/29/2006 9:43:02 PM
Hi;
We have image links via ButtonField and when it is disabled, the link does
not work but the image looks the same. Any suggestions to make the image look
disabled?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreports.... more >>
How do I get a bitmap from the theme?
Posted by David Thielen at 10/29/2006 3:48:02 PM
Hi;
I created a control and I think I should get the bitmaps it uses from the
theme. How do I set that up?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreports.com/film.htm
... more >>
Visual Development of Web Controls for SharePoint
Posted by Mike at 10/27/2006 7:47:01 AM
we are beginning to work with sharepoint. I have a book that documents how
to code server controls. I see in visual studio 2005 that there are
componets to create web parts. Can I use these componets to develop web
parts for share point 2.0 and if so how do I get them, with the code behind,... more >>
extending web controls
Posted by JJ at 10/26/2006 5:21:30 PM
I am trying to create custom controls that extend some of the functionality
of web controls (and sets default values if that control is used). For
example, if i were to use the textbox control, it should always use certain
font, size etc. I know I can do this by creating web control library ... more >>
Can a repeater's ItemTemplate instantiate derived classes?
Posted by Big Daddy at 10/26/2006 11:25:07 AM
I would like to have a repeater class like this:
<asp:Repeater ID="CriteriaRepeater" runat="server" >
<ItemTemplate>
<uc1:BaseControl ID="BaseControl1" BindData='<%#
Container.DataItem %>' runat="server" />
</ItemTemplate>
</asp:Repeater>
The thing... more >>
only for expert: what's wrong with this code?
Posted by Cas at 10/25/2006 9:14:26 PM
Hi,
I want to use a detailsview only for inserting data into a database (for a
survey). In order to check the inputted data, i need Templatefield.
So I defined a detailsview and a SqlDataSource in the aspx file.
The creation of the templatefields are done programmatically, because the
numbe... more >>
Enabling Windows Authentication from inside Forms Authentication (ASP.NET 2.0)
Posted by Michael D. Ober at 10/25/2006 2:52:40 PM
I need the ability to bypass the forms authentication login page when the
user requesting the protected page is running on our corporate network and
is also logged into the corporate domain. How do I do this?
Thanks,
Mike Ober.
... more >>
possible calendar bug
Posted by Abraham Andres Luna at 10/25/2006 1:00:31 PM
hello everyone,
i'm having a hard time setting the selected date in a custom control. below
is the custom control code:
using System;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace IS.WebControls
{
public class ISBaseCalendar : Control
{
Calendar cCalendar;
protected... more >>
ButtonField and Eval
Posted by David Thielen at 10/25/2006 9:51:01 AM
Hi;
In ButtonField for the text I want to do:
Text='<%# Eval("Title", Resources.Windward.ReportList_Confirm) %>'
Where the resource has a {0} in it for the Title property. This doesn't work
- says I need a DataBinding event. Is there a way to do this?
And why do none of the DataControlF... more >>
asp.net 2.0 gridview controls - bound or unbound?
Posted by pol_c NO[at]SPAM btinternet.com at 10/25/2006 3:52:17 AM
I am fairly new to asp's and .Net and I would like to use a session
variable when defining the Select Command for a gridview but it doesnt
seem to like it (see code sample below). Does anyone have any
suggestions?
<asp:SqlDataSource
ID="SqlDataSource1"
runat="server"
... more >>
Javascript and asp.net - TextBox backcolor not changing...
Posted by avanti at 10/24/2006 1:52:30 PM
i have a following javascript function that gets called on a checkbox
click. The backcolor is not getting changed for the textbox. I am
seeing an error on page as well. I am using IE and C# with the asp
code.
function enableExterNameTextBox(obj)
{
var textbox = "";
textbox = documen... more >>
GridView - ObjectDataSource - Dynamic Columns
Posted by Philip at 10/24/2006 9:21:02 AM
I can use a GridView and ObjectDataSource to bind my data using "Eval"
expressions ... provided the GridView and related Column TemplateFields are
defined as inline HTML.
I prefer to programmatically create the GridView Column/ TemplateField
definitions at runtime.... because I do not know ... more >>
javascript and navigateurl
Posted by acadam at 10/24/2006 3:55:29 AM
Hi,
I have an userControl .ascx with a gridView control. One of the columns
is a TemplateField with an HyperLink control. On the Row_DataBound
event, I am checking that one of the other columns contains a value,
then I would open a pop-up window. I am showing the HyperLink control
only sometime... more >>
a bug in BaseValidator.RegisterValidatorCommonScript() implementat
Posted by Dusan Hlavaty at 10/24/2006 3:03:02 AM
I think, I found a bug in 'BaseValidator.RegisterValidatorCommonScript()'
method implementation.
I looked at the source code through 'Reflector'. There is a
'IsClientScriptBlockRegistered(...)' method call, but I really think that
there may be 'IsStartupScriptRegistered(...)'.
This bug d... more >>
way to make 2 GridViews line up
Posted by David Thielen at 10/23/2006 1:05:02 PM
Hi all;
I have a couple of pages where I have a GridView, some text, then a secong
GridView. Both GridViews display the same type of data (different selects)
and I would like their columns to line up. Is there any way to do this other
than forcing the width on each?
--
thanks - dave
d... more >>
WebParts & Highend Portals
Posted by Victor Daicich at 10/23/2006 10:54:08 AM
Hi guys, just a simple question.
I've been working with the webpart framework, and i know it can work for
anonymous users. So the question is, would you recommend in terms of performance
and scalability for the development of a 10.000/15.000 visitors per day site.
It's a public portal.
W... more >>
Gridview sorting event - Gridview Datasource always Null .. why???
Posted by jobs at 10/23/2006 9:19:33 AM
The Grid displays with multiple rows. I select a column to sort of a
particular field and the below event is fired, but DataTable is Null so
code is skipped.
The GridView:
<asp:GridView ID="ChargeGridView" runat="server"
AutoGenerateColumns="False" DataKeyNames="RouteCode... more >>
Determine if a Gridview column is readonly programatically
Posted by Angel at 10/23/2006 9:15:02 AM
How can I determine that a column on my gridview is set to readonly in my
codebehind?
In other words I like to find out if a column in my grid is not editable....
thanks... more >>
Empty results hide GridView headers
Posted by jean-pierre.riehl NO[at]SPAM bewise.fr at 10/23/2006 12:38:38 AM
Hi,
With ASP.NET 2.0 (I don't remember about a such problem in 1.1),
GridView control has a strange rendering rule. When dataview is empty
(no data or data fitered), GridView control ONLY renders
<EmptyDataTemplate> (or EmptyDataText property). It is impossible to
render columns headers (and... more >>
CustomValidator inside Repeater is ignored
Posted by David Thielen at 10/22/2006 10:46:02 PM
Hi;
The OnServerValidate is called in my CustomValidator which is repeated once
each row in a Repeater - but it still lets me click next to go to the next
page.
Is there something else I need to do?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle... more >>
3 step wizard - ignore last step
Posted by David Thielen at 10/22/2006 9:22:02 PM
Hi;
I have a 3 step wizard. In some cases when they go from [0] to [1] I know
that I do not want to show page [2] but instead want [1] to be the last page
with the finish button.
What is the best way to implement this?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardre... more >>
asp:Repeater and asp:Table
Posted by David Thielen at 10/22/2006 2:56:01 PM
Hi;
Is there a way to build a table using asp:Repeater where the asp:Table is
started in the header and ended in the footer? Everything I have tried does
not work.
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreports.com... more >>
Can't duplicate ID in subclassed GridView
Posted by David Thielen at 10/21/2006 8:51:01 PM
Hi;
I switched two controls from GridView to EmptyGridView. When it was GridVIew
both controls (on the same page) had a
<Columns><TemplateField><ItemTemplate><LinkButton ID="DeleteButton"... and it
was ok that both had the same ID name.
Once I switched to EmptyGridView that is now an err... more >>
My own control - exception in Design view
Posted by David Thielen at 10/21/2006 4:18:01 PM
Hi;
When I switch to design view the control I created (inherits from HyperLink)
displays:
Error Rendering Control - HelpLink1
An undandled exception has occured.
Object reference not set to an instance of an object
Any ideas why this happens?
--
thanks - dave
david_at_windward_dot_... more >>
Anyone have APP_LocalResources resx files for the MS controls...
Posted by David Thielen at 10/21/2006 3:32:01 PM
Does anyone have APP_LocalResources resx files for the MS controls that they
will share? Obviously we can get VS 2005 to auto-generate them for English.
But if anyone has them in other languages and will share, we would really
appreciate it. (It also would be good if all websites used the same... more >>
Need button control that...
Posted by David Thielen at 10/21/2006 11:18:02 AM
I need a button control that does the following:
1) Has 3 bitmaps for button, OnHover, and OnClick.
2) Is placed in a grid and has a url that includes a {0} in the url that is
set with a property from the data for that row of the grid.
3) Preferably has a text (for when the cursor is over it)... more >>
menu question
Posted by David Thielen at 10/20/2006 4:45:02 PM
Hi;
A couple of menu questions:
1) I would like to have a menu that is horizontal with graphic tabs for
background images. How do I set this?
2) For some of the main menu items, I want to have 2 or 3 sub menus. I would
prefer that they appear horizontially. How do I set this?
3) When... more >>
all bitmap button in grid?
Posted by David Thielen at 10/20/2006 4:23:02 PM
Hi;
I want to have a button in a cell of a grid (in each row) where the button
is just a bitmap - no text. Which control should I use? Just a plain old
asp:ImageButton?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreport... more >>
how to validate input of a detailsview?
Posted by Cas at 10/20/2006 12:00:00 AM
Hi,
I use a detailsview control for inputtng data. I want to check the user
input before it is sent to the database (min. /max value, not empty, only
some values allowed ...). When clicking on the insertbutton, i want a
warning if one or more inputs are not correct and the user must have th... more >>
auto-size textbox
Posted by Jerry C at 10/19/2006 9:08:02 AM
I have a text box on a asp.net web page. The text is from a dataset field.
The length of the text can be anywhere from 0 to 2000 chars. what is the best
way to resize the textbox to fit the text. I find some information about
using the graphics library. Is this the best way.
--
Jerry ... more >>
Textbox - inserted enters
Posted by RBM at 10/19/2006 4:31:56 AM
Hello,
On my ASP.NET 2.0 page I have a textbox with edit type multiline.
I have the following question:
Is it possible to show manualy typed enters in the Gridview inserted
from such a textbox?
Please anser this question, thanks in advantage.
Greetings,
Ren=E9 Beltman
... more >>
Datagrid template column
Posted by chandu at 10/19/2006 12:00:00 AM
Hai,
i put template column in datagrid. then if i want to display date in that
column (only date with out default time).can u tell me that option to
display only date with out tme.
if it is datagrid bounded column then it will come.
i want for template column.
thank u ..
... more >>
GridView RowComand event Issue
Posted by J Li at 10/18/2006 3:33:02 PM
In the footer of the gridview, I have a dropdown and a "Add" button set up,
so I can add new rows to the gridview. The "Add" button has CommandName of
"ADD", so I use that in the GridView1_RowCommand to check if (e.CommandName
== "ADD") before I add the row.
Everything works fine except, a... more >>
Display an empty grid
Posted by David Thielen at 10/17/2006 9:07:02 PM
I would swear I asked this yesterday - but I can't find my post (or any
answers). So here goes again.
In a GridView, when it is empty, instead of a message, I would like the grid
to display, preferably with a single empty row but having just the header and
no rows would be ok. How can I do ... more >>
good sample of creating my own web control?
Posted by David Thielen at 10/17/2006 8:59:01 PM
Hi;
Does anyone know of a url that shows the "right" way to create my own web
control? I need to inherit from asp:HyperLink and add some minor additional
functionality.
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreport... more >>
changing rows in a multiline textbox
Posted by carlor at 10/17/2006 12:44:02 PM
Hi there,
I have a situation where I have a textbox that by default only displays 2
rows of text at a time (textbox.rows = 2). On a link button click, I am
supposed to expand the textbox to show all the data it contains but there are
a number of problems to work through:
- the text box i... more >>
localization for all MS web controls
Posted by David Thielen at 10/17/2006 10:11:02 AM
Hi;
Does anyone know of a set of localization files that localizes all the MS
web controls for various languages? I'ld much prefer that to localizing them
ourselves, both because it saves us time/money and because then we will be
using the exact same words that other sites use so it's a sta... more >>
implicit vs explicit localization
Posted by David Thielen at 10/17/2006 9:58:02 AM
Hi;
Any comments on which is the better approach? And why?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com
Cubicle Wars - http://www.windwardreports.com/film.htm
... more >>
email sending twice
Posted by Janet at 10/17/2006 7:05:54 AM
With the code below, every email is sent twice. Anybody tell me why?
Dim txtBody as string
txtBody = "testing 2.0 email"
Dim MailObj As New System.Net.Mail.SmtpClient
MailObj.Host = "localhost"
MailObj.Send("webmaster@email.net", "donkey@email.net", "Online Search Request", txtBody)
MailO... more >>
Adding Web Control
Posted by Duncan Dimech at 10/17/2006 1:40:42 AM
Dear All
I am writing a tool which requires to have controls added to it dynamically.
To make the task more complex, the addition of the control cannot happen
anywhere but it has to be instead of a token
example
<p> this is a test <textbox /> and a text box should be entered </P>
the ... more >>
Request for the permission of type System.Web.AspNetHostingPermission failed
Posted by Allan Ebdrup at 10/17/2006 12:00:00 AM
I'm using dotNet 2.0 and VS2005.
I've got a class library where I've created a webcontrol (Inherits from
GridView).
The dll for the class library resides on a different server (development
server)
Now I have a website ASP.Net 2.0. When I add a reference to the dll I don't
get my control in ... more >>
AccessDataSource - how to get access to the retrieved data?
Posted by Martin at 10/16/2006 11:08:01 PM
I am using the new AccessDataSource control and it works as expected (query
result bound to a GridView).
Very nice about this control is that it keeps the data in memory. (a
Dataset). But how can I get that data, and use it elsewhere in my code?
I have read that a method exists (GetView) ... more >>
|