controls

Multiple type of controls in the same header in the datagrid in Silverlight

I want to design the property window in Silverlight by using DataGrid. It will have two header columns. The value header can have the different types of controls. It might have combobox, textbox and other controls. Here is the view for the datagrid. Name--------------Type of the control(Control to display) DisplayText-------TextBox Typ...

2 column table presentaion control, like the properties window in the dev environment

in a windows form if i want to duplicate the properties window layout on my form, which is basically a 2 column table with title on the left and value on the right, what control do i use to achieve that? ...

Using customized line images in Asp.Net Treeview control

When I use my own line images for customizing the look and feel of the treeview control, there appears to be a rendering problem in the table row that creates the "I" line. The Lminus, Lplus, R etc line rows all gets rendered without a problem, but for some reason the "I" line gets rendered inside a div tag as follows: <td> <div style="...

ASP.NET - Loading controls at one time (on application load)

Hi, We are working on an ASP.NET application. It has 3- 4 forms displaying country list dropdown. Here we would like to avoid binding these dropdowns each time by getting data from database. Instead looking for a better practice of binding it one time, say on application load/some other. Would you please let me know how we could...

How to send a CBN_SELCHANGE message when using CB_SETCURSEL ?

When using the CB_SETCURSEL message, the CBN_SELCHANGE message is not sent. How to notify a control that the selection was changed ? P.S. I found on the Sexchange site, a very ugly hack : SendMessage( hwnd, 0x014F/*CB_SHOWDROPDOWN*/, 1, 0 ); SendMessage( hwnd, 0x014E/*CB_SETCURSEL*/, ItemIndex, 0 ); SendMessage( hwnd, 0x0201/*WM_LBU...

Persisting User Input for Dynamic Control in SharePoint Web Part

Edit at bottom with solution I've seen a similar question to this posted before and have tried the suggestions, but I must be missing something. My basic problem is this: I have a select box where the user can select a filter which may or may not have constraints built into it (requires the user to input further data so the filter know...

Linq to SQL Design question

Often I need to combine data from multiple tables and display the result in a GridView control. I can write a Linq query inline in the Page_load event, return an anonymous type that combines all the fields that I need, and databind the result to the GridView control. Problem: I use 'helper methods' as described by Scott Guthrie on hi...

How to append dynamically created Windows Forms controls?

While I can easily accomplish in ASP.NET using AddAt(), I am trying to do the same thing in Windows Forms. I have a panel, and while I can do a pnlMyPanel.Controls.Add(ctl) ... it always inserts it in the 0 position, when I would rather have it appended to the end, or pnlMyPanel.Controls.Count. Am I overlooking a method or am I going t...

Apply css control adapters to existing moss publishing site

Hi We have an existing moss publishing site. When we enable the css control adapters for our menu, they only seem to apply to newly created sites. How can we apply this to existing sites? ...

C# Get a control's position on a form

Hi Is there any way to retrieve a control's position in a form, when the control may be inside other controls (like Panels)? The control's Left and Top properties gives me only it's position within it's parent control, but what if my control is inside five nested panels, and I need it's position on the form? Quick example: The button...

Wpf: Listing all control Names in an application

I need a way to list out all named controls in a wpf application. In C++ we could use the resources file to see a list of all the controls on a form(or so I'm told). I need a similar way to see the a list of controls in a wpf application. The names will be used in a database, so it doesn't matter how I get them, I just need to automate...

Hiding dashed outline around trackbar control when selected

Hello, In C# winforms, is there a way to not show the dashed focus outline border that shows around a trackbar control when it is being used? Details: This outline looks kinda tacky to me, so I'm just shooting for aesthetics to not show it. Thanks, Adam ...

Howto draw "pages" in a C# WinForms project

Hi, I want to display data on a Windows Forms project in C#. The general sketch for the GUI is similar to Acrobat Reader or MS Word - meaning i want to display the data on several pages, and let the user navigate between the pages. The data i`m displaying isn't special, i just want to give the user a "page" feeling when viewing it. I...

Accessing value of dynamically created controls c# asp.net

I'm trying to access the value of a selected radioButton. I have a list of radio button's seperated by sub headers (hence why i havent used a radioList) I don't know how to access the selected value as i'm not sure what name it's given with it being dynamic. The following code is in a for loop and outputs radio options. All the options...

defining events for html control running at server in c# page

i have a custom control which consists of html select and html inputtext and i want to define the events for that custom control running at server in c# page ? i wan to write code for that custom control click event in c# page? can any one help me in that. ...

create dynamic controls with ASP.NET MVC

Hello Everyone, In my current application we create controls dynamically inside panel based on database value. Like, Type controls, Style, width, etc. Is it possible to do something like this using ASP.NET MVC? Thanks, Alps ...

Declarative event handling from ASP.NET user control to page

Hello, I am trying to figure out how to declaratively pass in a event handler into a user control, but I am stumped. All I can make work is the user control's event handler.. I can't seem to bubble up the caught event into the parent page. Ideas would be quite welcome. Here is my code: Default.aspx: <%@ Page Language="VB" %> <%@...

Dynamically add controls to a silveright StackPanel to Create a menu

hello community any one can please say how to add controls dynamically into a Stack Panel note: what i need is i have to create a menu which get data from database and creates menu items accordingly can any one say how can i create such menus i am new to silver light I am using silverlight 3 beta and expression blend3 + sketch flow ...

Adding Control based on info in txt file

Following code, credit: Guffa. Hello All, I'm trying to add controls to a Form at runtime based on the information found in a Plain Text File. The structure? of the text file is always the same, and will not change. Example: File.txt: Label "This is a label" 320, 240 Explanation: Control Text Location The following code, pr...

Help finding the deepest Child Control for SpellChecking

I am trying to Refactor this code as it is repeated ad nauseum throughout my program. My problem has to do with the fact that on any given page(tabpage,panel,uc,etc) there are controls at multiple levels to spellcheck. i.e. --> foreach (Control control in tpgSystems.Controls) { if (control.GetT...