Search Results

Search found 23367 results on 935 pages for 'aix grid control'.

Page 44/935 | < Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >

  • Working with Windows Forms CheckBox Control using C#

    A CheckBox control allows users to select a single or multiple options from a list of options. In this article, I will discuss how to create a CheckBox control in Windows Forms at design-time as well as run-time. After that, I will continue discussing various properties and methods available for the CheckBox control.

    Read the article

  • WPF Lookless Control Events

    - by Scott
    I have the following class: public class LooklessControl : Control { public List<int> IntList { get; private set; } public int CurrentInt { get; private set; } private int _index = 0; static LooklessControl() { DefaultStyleKeyProperty.OverrideMetadata(typeof(LooklessControl), new FrameworkPropertyMetadata(typeof(LooklessControl))); } public LooklessControl() { IntList = new List<int>(); for (int i = 0; i < 10; i++) { IntList.Add(i); } CurrentInt = IntList[_index]; } public static readonly RoutedCommand NextItemCommand = new RoutedCommand("NextItemCommand", typeof(LooklessControl)); private void ExecutedNextItemCommand(object sender, ExecutedRoutedEventArgs e) { NextItemHandler(); } private void CanExecuteNextItemCommand(object sender, CanExecuteRoutedEventArgs e) { e.CanExecute = true; } public static readonly RoutedCommand PrevItemCommand = new RoutedCommand("PrevItemCommand", typeof(LooklessControl)); private void ExecutedPrevItemCommand(ExecutedRoutedEventArgs e) { PrevItemHandler(); } private void CanExecutePrevItemCommand(object sender, CanExecuteRoutedEventArgs e) { e.CanExecute = true; } public static readonly RoutedEvent NextItemEvent = EventManager.RegisterRoutedEvent("NextItemEvent", RoutingStrategy.Bubble, typeof(RoutedEventHandler), typeof(LooklessControl)); public event RoutedEventHandler NextItem { add { AddHandler(NextItemEvent, value); } remove { RemoveHandler(NextItemEvent, value); } } private void RaiseNextItemEvent() { RoutedEventArgs args = new RoutedEventArgs(LooklessControl.NextItemEvent); RaiseEvent(args); } public static readonly RoutedEvent PrevItemEvent = EventManager.RegisterRoutedEvent("PrevItemEvent", RoutingStrategy.Bubble, typeof(RoutedEventHandler), typeof(LooklessControl)); public event RoutedEventHandler PrevItem { add { AddHandler(PrevItemEvent, value); } remove { RemoveHandler(PrevItemEvent, value); } } private void RaisePrevItemEvent() { RoutedEventArgs args = new RoutedEventArgs(LooklessControl.PrevItemEvent); RaiseEvent(args); } private void NextItemHandler() { _index++; if (_index == IntList.Count) { _index = 0; } CurrentInt = IntList[_index]; RaiseNextItemEvent(); } private void PrevItemHandler() { _index--; if (_index == 0) { _index = IntList.Count - 1; } CurrentInt = IntList[_index]; RaisePrevItemEvent(); } } The class has a default style, in Generic.xaml, that looks like this: <Style x:Key="{x:Type local:LooklessControl}" TargetType="{x:Type local:LooklessControl}"> <Setter Property="Height" Value="200"/> <Setter Property="Width" Value="90"/> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type local:LooklessControl}"> <Border BorderBrush="Black" BorderThickness="1" Padding="2"> <Grid> <Grid.RowDefinitions> <RowDefinition Height="20"/> <RowDefinition Height="*"/> </Grid.RowDefinitions> <Rectangle Grid.Row="0" Fill="LightGray"/> <Rectangle Grid.Row="1" Fill="Gainsboro"/> <Grid Grid.Row="0"> <Grid.ColumnDefinitions> <ColumnDefinition Width="10"/> <ColumnDefinition Width="*"/> <ColumnDefinition Width="10"/> </Grid.ColumnDefinitions> <Path Grid.Column="0" x:Name="pathLeftArrow" Data="M0,0.5 L1,1 1,0Z" Width="6" Height="14" Stretch="Fill" HorizontalAlignment="Center" Fill="SlateBlue"/> <TextBlock Grid.Column="1" Name="textBlock" Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=CurrentInt}" HorizontalAlignment="Center" VerticalAlignment="Center" FontFamily="Junction" FontSize="13"/> <Path Grid.Column="2" x:Name="pathRightArrow" Data="M0,0 L1,0.5 0,1Z" Width="6" Height="14" Stretch="Fill" HorizontalAlignment="Center" Fill="SlateBlue"/> </Grid> <ListBox Grid.Row="1" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Background="Transparent" ItemsSource="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=IntList}"/> </Grid> </Border> </ControlTemplate> </Setter.Value> </Setter> </Style> How do I make it so that when the user clicks on pathLeftArrow it fires LooklessControl.PrevItemCommand, or or they click on pathRightArrow and it fires LooklessControl.NextItemCommand, or they click on an item in the ListBox and LooklessControl is notified of the newly selected item? In other words, without adding x:Class to the top of Generic.xaml and thus creating a code-behind file for it, which I assume you wouldn't want to do, how do you handle events for elements in your xaml that don't have a Command property (which is just about everything other than a Button)? Should LooklessControl have it's own XAML file (much like what you get when you create a new UserControl) associated with it that Generic.xaml just pulls in as a MergedDictionar as its default template? Or is there some other acknowledged way to do what I'm trying to do?

    Read the article

  • dojox.grid.DataGrid can't display repeat rows?

    - by Robert
    We have a situation where we need to display data from a database in a grid which has repeat rows, but it seems at least the basic examples fail when the cell data is identical with Sorry, an error occurred. An example follows: <script dojo.require("dojo.data.ItemFileWriteStore"); dojo.require("dojox.grid.DataGrid"); var historyData = { 'identifier': 'time', 'label': 'time', 'items': [ { 'message': 'Please turn in your TPS reports immediately', 'time': 'March 3 2010 7:20 AM', 'sentBy':'Bill Lumbergh' }, { 'message': 'Please turn in your TPS reports immediately', 'time': 'March 3 2010 7:20 AM', 'sentBy':'Bill Lumbergh' }] }; var historyGridLayout = [ [{ field: "message", name: "Message" }, { field: "time", name: "Display Date & Time" }, { field: "sentBy", name: "Sent By" }]]; </script <body class="tundra " <div dojoType="dojo.data.ItemFileWriteStore" data="historyData" jsId="historyStore" </div <div id="grid" dojoType="dojox.grid.DataGrid" store="historyStore" structure="historyGridLayout" </div </body Help!

    Read the article

  • FloatableWindow resizes Grid in Silverlight

    - by Ben
    I'm trying to use Tim Heuer's FloatableWindow control for a non-modal options window in my Silverlight application. However, I'm running into a problem with the FloatableWindow resizing it's parent grid when it opens. For example, before I open the window the application looks like this: But after opening the window, the first row of the grid expands: I'm currently setting FloatableWindow.ParentLayoutRoot to the LayoutRoot grid in MainPage.xaml. Is this the right thing to do? How can I prevent the grid from resizing when the FloatableWindow opens?

    Read the article

  • IBM's RTC and Microsoft's TFS 2010

    - by gkdm
    Hi, What in your view are the most important differences? Need to make an expensive decision... Thanks. Information: We have both Java and .Net Projects (few more .net) Very interested in project life cycle management. Migrating from ClearCase

    Read the article

  • using dojox grid in xpages

    - by Tarun
    how to use dojox datagrid in xpages? If anyone have code snippet please send it to me at [email protected] I am trying with the following code but getting nothing at the output: <xp:this.resources> <xp:dojoModule name="dojox.grid.DataGrid"></xp:dojoModule> <xp:dojoModule name="dojox.grid"></xp:dojoModule> </xp:this.resources> <xp:panel > <xp:scriptBlock id="scriptBlock1"> <xp:this.value><![CDATA[makeGrid = function(){ dojo.require("dijit.form.Button"); dojo.require("dojox.grid.DataGrid"); var subrow1 = [{name: "Product Title"}, {name: "Price"}, {name: "Type"}]; var view = {rows: [ subrow1 ]}; var structure = [ view ]; var data = [ ["Baseball gloves", 12.34, "Sports"], ["Tennis ball", 5.99, "Sports"], ["T-shirt", 12.45, "Clothing"], ["Hat", 12.45, "Clothing"] ]; var productModel = new dojox.grid.data.Table(null, data); productModel.render(); }; XSP.addBeforeLoad(makeGrid);]] <div dojoType="dojox.Grid" autoWidth="true" model="productModel" structure="structure" </xp:panel> Please help !!

    Read the article

  • How do I deselect grid row when grouping in David Poll's silverlight CollectionPrinter

    - by kpg
    I'm using David Poll's CollectionPrinter and modifications by Fama to perform grouping. I'm using the control to print a datagrid with grouping and it works well if not a little slow. Problem: When the grid is displayed the first row of the grid is selected and the first cell of the row is also selected. I want to either deselect the row or change the datagrid template to make selected rows/cells appear as not selected. I tried to specify a grid template to change the row/cell selection appearance but when I added the default template I got a COM error of all things - anyway I concluded that what I was doing was not compatible with the SLab libraries, or perhaps because the grid was specified in a datatemplate. In any case I abandoned that approach. Since I have the SLab source if I understood it more there may be a way to deselect the row after from that side of things - but I know the SLaB CommectionPrinter does not rely on the data template to be a grid, so I'm not sure how to modify the code to accomplish what I want. Question: How can I prevent the row from being selected or deselect it once it is or change the appearance of the selectd row when using the CollectionPrinter with grouping? Note that the row selection problem may occur without grouping as well, I don;t know, but it definatly does with grouping.

    Read the article

  • How to update Child grid in asp.net using LINQ

    - by Raj Kumar
    Hi I have an asp.net page where i am using LINQdatasource to bind grid. Now whenever, if some one changes something in grid I want to update a history table. which is also shown as child grid for each row Let say I have a grid with two column Name and Age. it also has a child row with column field and datetime. so when ever if some one changes something in Name or Age column and saves it. A new row is inserted in child row with the name of field changed and date time when it was changed

    Read the article

< Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >