For my web application,
I want a 10*10 (100 cells which is created dynamically) grid to be displayed in the following manner.
Initially all the cells' color is green.
If i click on any cell its color becomes red if it is green and if i click again it becomes red.(Toggle the cell color)
I should be able to display dynamic number of link buttons in each cell.On the click of which it pop ups a window.
Are there any control available for this? Or how can I implement this functionality.
You can achieve this behavior very easily using jQuery.
You might want to look into some function like:
Click
Toggle
Live
I don't recommend you to do it with C#, you would have to place an UpdatePanel and cause a postback just to change the cell colors.
Related
I would like to reproduce a Control in my WindowsFormsApplication that is equal to the refresh Button of the Windows Network connection form.
Does anybody know which Control it is or how to build a equal one in C#? It seems to be a PictureBox but if you hover it with the Cursor it gets a semi transparent blue colored overlay.
you can use XanderUI for this, add the button, change the button image and change both hover and click background colors to whatever color you like
I am a c# silverlight developer and i am under a situation where i have created GUI using c# only(no use of xaml) .
How i created this GUI :
I have coded for it in c# and there is 1 grid(with 3 number of rows) and inside that grid i have 3 more grids in each row of previous grid one corresponding to "Automatic Skewing" another grid in second row corresponds
to "Auto Model" and the third one corresponds to "Skew".
What i have to do ?:
Please note that the grid in third row contains a semi-transparent GUI. I want to do my gui semi transparent like this because i want to display the
GUI of the third row but i don't want to the user to click(edit) on third row , he must be able to see it with semi transparency (but can not click on it as you can see the third row (corresponding to skew) in snapshot below it is semi transparent and user cannot click on it).
How to achieve this using c# code only(not xaml). Any Idea ?
As you can see the Skew grid (3rd row) is semi transparent.
Based on your specification I think it would be the best to put all content of the third row into some container, set the IsEnabled property of it to false(as SilverLight's Grid seems to lack this property, you can try to wrap it in a ContentControl), and also set an Opacity lower than 1 to it.
Both the IsEnabled and the Opacity property affects the child elements.
Maybe it would be better to actually bind those values, as I suspect that the enabled/disabled state of the third row depends on some condition. (Both values - IsEnabled and Opacity - can be bound to the same condition, in case of the opacity you might want to use a converter)
By the way: I feel it would be much easier with XAML...
I'm working on a GUI built with C# in Visual Studio 2010. I want to change the color of some of my buttons, which I can do in the properties of the button, but a small border remains around the edge of the colored part of the button. When the button is clicked or focused on, this border changes to the default blue. Like this:
How can I change the highlight color of the button? Also, is there a way to change the color of the button while maintaining the default (horizontally divided two-tone) look?
Thanks for your help,
Dave
I am working on a custom control based on a ListView control. The goal of the control is to show the events name in the first column and the event duration on a timeline on the second column. I've implemented the custom drawing for the timeline section and it all works.
Now I would like to implement a "zooming" feature. Where the user would be able to click somewhere on the second column drag the mouse and upon release the timeline would be zoomed in with starting and end times matching the mousedown/mouseup events.
Currently when I click/drag the mouse, a normal selection box appears. I would like to overide that such that I get don't get a box but more of a vertical area (so the selection is only based on the timeline axis).
I really don't know where to look and how to overide the drawing the selection box. Any pointers/sample code would be appreciated.
Well if you don't need multi selection option setting MultiSelect property to false disables rubber band selection.
I'm using the DatePicker control from the WP7 SL toolkit. It navigates to DatePickerPage.xaml, which has the scrollers for date picking. I want to keep all the functionality, but change the colors. I'm messing around with DatePickerPage.xaml and updating colors to fit my needs.
I've been able to update the text colors on the scrollers and header, but I can't figure out how to update the background color on the selected item in each or the square outline while the scroller is active. Based on tests I have done with changing the background color of the DatePickerPage.xaml, it appears that the selected item and square outlines are an opaque version of the background color. Unfortunately, this wont work for me, since I want the background to the be white and the outlines aren't visible. Is there a way to explicitly set those colors?
If you get the control into Blend and right click on it and select Edit Tempate --> Edit a Copy, you'll get the template for the control so that you can edit it.
What you'll be looking for is the resources keys that are used for the background, foreground, etc. You can replace them with your own resources, or hardcode them, or the best option is to override the resource.
Additional Advice
Be careful though, don't forget that a user can have either a dark or light background to the phone, so unless your app is taking control of the background color of the whole page, you need to consider what might happen when picking colors