custom-controls

Delphi, Override Custom controls setCaption

i have a custom control, with the Ancestor being another custom control, who's Ancestor is a TPanel; i.e. TNotMyCustomControl = class(Tpanel); TMyCustomControl = class(TNotMyCustomControl); Is i possible to react when the Caption is being set (run time or design time), and still have the changed passed to the Ancestor controls? ...

.NET Graphics on Windows 7: White corners around images?

I've been working on some custom graphics controls, and I found this weird problem with windows 7 rendering my button controls. I've used Photoshop to delete the pixels in the background all around the button image I'm using, then saved it as a GIF, and imported it into VS to use as the background image of my button. When windows XP re...

How To Create Cross Browser Asp.net Custom Control

I'm goingto create an asp.net control which should be cross browser. and support some skin - multilanguage and rtl & ltr support. I want to know what should I consider and also looking for a good article ...

Custom Play Pause Button Iphone

Heya, I'd like to ask what is the best way to achieve the following coding with cocoa for IPhone. As a learning exercise I'd like to make a very simple mp3 player. The part I'm most interested in at the moment is the custom visual components for this player. In particular how would I make a custom play pause button with mouseover and ...

Delay rendering of a custom control in WPF

I have a WPF custom control that sometimes takes a while to render in some complex scenarios. I would like to be able to tell my custom control to show a placeholder image (e.g. "Please wait - rendering!") and then actually render the control in idle time (after input is processed). I am thinking along the lines of having my custom cont...

Textbox search with dropdown results

I (think I) want to develop a custom control for my program in VB .net where I type into a textbox and simple search results will then be displayed underneath it (from a predefined set of items). Like auto suggest in google search. I believe the combobox does something similar to this but I think it only works on prefixes. At the momen...

Custom ListBox : Elegant & effective implementation ?

All, I'm currently working on some ListBox customization in order to improve the clearness of my app. Basically, it is quite easy to find 'how to' for this purpose leading to my current result below. I'm happy with the display but ... I faced strange behavior with the mousewheel. I tried to find information on this issue and I found...

ASP.NET: How to process postback events for my own control?

I have my own Control1 which is dynamically added as child control to Control2 which implements INamingContainer in CreateChildControls() of control2. Control1 itself implements IPostBackEventHandler. But RaisePostBackEvent() method is never called on Control1, despite I do call postback method from JavaScript. And yes, there are other...

provide properties in design time by custom controls (.NET)

I create some control and i define some properties who can define in desing time, but only shows one. Another issue is that in the one shown, the textbox of the form was displayed, but i can't select any. [Description("Blah Blah Blah"), Category("Data"), DefaultValueAttribute(typeof(TextBox), null), Browsable...

JComponent is not visible, anyone knows why?

Here's my JFrame code: public static void main(String[] args) { JFrame jf = new JFrame(); jf.setSize(600,600); jf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); MyCustomWidget widget = MyCustomWidget.createWidget(400, 400); widget.setVisible(true); // just to set x and y widget.setLocation(40, 40); jf....

Selector that can only take child elements of a certain type?

I need to write a control that is supposed to take only a certain type of child controls. Functionally it works like a Selector in that I can select/activate on of its childs but it seems that I can not derive from Selector because an ItemsControl can take any type of child (object). I really would like to have compiletime typesafety her...

WPF detect scrolling parent Control

Imagine the situation you open a WPF Popup(e.g. through ButtonClick). You have a ListBox directly in the Popup with some items, so you have to be able to scroll. Imagine that this is your Custom Control and it's located in the ScrollViewer. Now if you move with your mouse outside from the Popup surface and scroll, what happens? You scro...

How to Overwrite Internet Explorer Dialog's ?

I'm looking for a way to overwrite for example the dialog which pops up if you click on the "browse"-Button of a INPUT type="file" element in an HTML Page. I need to suppress the original dialog and show my own implementation. Is this possible in any way ? ...

How to enable ajax when deriving from System.Web.UI.WebControls.WebControl on controls that are created inside WebControl

I've built a class that derives from System.Web.UI.WebControl. It basically renders pagination links (same as what you see on top of GridView when enabled) for use above a repeater. I'm creating some anchor tags explicitly inside my nav control obviously, but they don't perform ajax postbacks. My understanding is that ajax requires POS...

show Select URL box for ClickImageURL in Custom ImageButton

Dear All, I am making a custom ImageButton Control which has the option to show button clicked effect by adding onmouseup and onmousedown javascript code to change image URL. I have constructed the control and it has a ClickImageUrl to set the URL of image to be shown when button is clicked.. i wanted to know is there any way i can add...

How to move ASP.NET PlaceHolder control from Page controls collection to a custom Control's output?

I am writing an ASP.NET custom control. In my custom control code, I find a PlaceHolder control in the page like so: this.myPlaceholder = Page.FindControl("placeholder1") as PlaceHolder; Then, I render the placeholder as the output of the custom control: protected override void Render(HtmlTextWriter output) { if (this.myPlacehol...

Preserve TableCell BackColor seted on client side on postback

What is the best way to save BackColor of asp:Tabel TableCell set on client side by javascript on posback ? What property do I override while creating custom control based on Table ? ...

Setting Focus to a .NET UserControl...?

I'm creating a custom control derived from UserControl that I would like to set focus to. The custom control contains a ComboBox control and I draw some strings beside it. The ComboBox can receive focus, but I would like to be able to set focus to the UserControl itself. My OnPaint handler is set up to draw the control slightly differ...

Mistake in Code.

Hi all. in Qt, i want to customize the listview in QT Symbian. so for the customization purpose i have set delegate for the listview. and i am handling the paint event also.. the problem is the text colour. i am not getting the default text colour, when the item is selected from the listview. i.e below sample code,i have two strings n...

record video programmatically on iphone

Hi, Is there public interface in SDK 3.* to start video recording programmatically? Also how can I customize camera button appearance? Thanks, Nava ...