Search Results

Search found 9 results on 1 pages for 'trindaz'.

Page 1/1 | 1 

  • WPF DataGrid cannot Add a row when datasource is empty

    - by Trindaz
    CanUserAddRows="True" only 'works' when there's already data in the itemsource of the data grid. If it just so happens that there are no rows in the original list of items, then the datagrid doesn't display a 'placeholder' row for entering new items, even though I've set CanUserAddRows="True". Why?! Thanks in advance, Trindaz

    Read the article

  • WPF DataGrid binding to UserControl

    - by Trindaz
    I have a DataGrid with one column using a UserControl via a styled DataGridTemplateColumn. I can't seem to get the UserControl to 'see' the object that is in it's containing DataGridCell though. What kind of bindings can I create on the TextBox in my UserControl so that it can look up and see that object?! My UserControl and TemplateColumn Style are defined as: <Window.Resources> <local:UCTest x:Key="UCTest" /> <Style x:Key="TestStyle" TargetType="{x:Type WpfToolkit:DataGridCell}"> <Style.Setters> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type WpfToolkit:DataGridCell}"> <Grid Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource drc}, Path=DataContext}"> <Grid.ColumnDefinitions> <ColumnDefinition/> <ColumnDefinition/> </Grid.ColumnDefinitions> <local:UCTest /> </Grid> </ControlTemplate> </Setter.Value> </Setter> </Style.Setters> </Style> </Window.Resources> and my sample DataGrid is defined as: <WpfToolkit:DataGrid Name="dgSampleData" ItemsSource="{Binding}" AutoGenerateColumns="True" Margin="0,75,0,0"> <WpfToolkit:DataGrid.Columns> <WpfToolkit:DataGridTemplateColumn Header="Col2" CellStyle="{StaticResource TestStyle}" /> </WpfToolkit:DataGrid.Columns> </WpfToolkit:DataGrid> and my User Control is defined in a separate file as: <UserControl x:Class="UCTest" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:local="clr-namespace:WpfApplication1" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Width="104" Height="51"> <UserControl.Resources> <local:DataRowConverter x:Key="drc" /> </UserControl.Resources> <Grid> <TextBox Margin="12,12,-155,16" Name="TextBox1" Text="" /> </Grid> EDIT: My implementation of TestClass, which has the Test Property, which I want UCTest.TextBox1 to bind do: Public Class TestClass Private _Test As String = "Hello World Property!" Public Property Test() As String Get Return _Test End Get Set(ByVal value As String) _Test = value End Set End Property End Class Thanks in advance!

    Read the article

  • WPF Binding to DataRow Columns

    - by Trindaz
    Hi, I've taken some sample code from http://sweux.com/blogs/smoura/index.php/wpf/2009/06/15/wpf-toolkit-datagrid-part-iv-templatecolumns-and-row-grouping/ that provides grouping of data in a WPF DataGrid. I'm modifying the example to use a DataTable instead of a Collection of entities. My problem is in translating a binding declaration {Binding Parent.IsExpanded}, which works fine where Parent is a reference to an entity that has the IsExpanded attribute, to something that will work for my weakly typed DataTable, where Parent is the name of a column and references another DataRow in the same DataTable. I've tried declarations like {Binding Parent.Items[IsExpanded]} and {Binding Parent("IsExpanded")} but none of these seem to work. How can I create a binding to the IsExpanded column of the DataRow Parent in my DataTable? Thanks in advance, Dave

    Read the article

  • Problems installing SQL Server 2008 on Windows 7 Pro

    - by Trindaz
    I'm having no luck. I've tried installing SQL Server 2008 Express on my Windows 7 Pro box about 4 times now. Each time it installs the 'setup files required' then does nothing. All I can do is click the 'New ... or Add Features...' link to try starting again but get the same results each time. Any developers experienced this before?

    Read the article

  • WPF DataGrid default column types

    - by Trindaz
    Hi, I'm using a DataGrid to display 2 possible types of DataRow in a DataTable. One type has the column Parent = NULL and the other has Parent set to another DataRow in the same DataTable. The list of column in the DataTable is always different, so explicitly describing each column is not possible. I want to display a UserControl in every cell of the Parent = DataRow rows, and default Text / Check boxes for the Parent = NULL rows. My first strategy is to try and set the default Column type for all automatically generated columns to be a DataGridTemplateColumn, regardless of datatype, so that I can use styles to then use either my UserControl or CheckBox or TextBox where required. How can I do this? More importantly, though, is there a better strategy than this? Cheers, Dave

    Read the article

  • SQL Server 2008 table variable error: Must declare the scalar variable "@RESULT".

    - by Trindaz
    I'm using table values for the first time as a parameter to a function in SQL Server 2008. The code below produces this error: Must declare the scalar variable "@RESULT". Why?! I'm declaring it on the first line of the function! ALTER FUNCTION f_Get_Total_Amount_Due( @CUSTOMER_LIST [tpCSFM_CUSTOMER_SET_FOR_MONEY] READONLY ) RETURNS [tpCSFM_CUSTOMER_SET_FOR_MONEY] AS BEGIN --Prepare the return value, start with initial customer list DECLARE @RESULT AS [tpCSFM_CUSTOMER_SET_FOR_MONEY] INSERT INTO @RESULT SELECT * FROM @CUSTOMER_LIST --Todo: populate with real values UPDATE @RESULT SET tpCSAM_MONEY_VALUE = 100 --return total amounts as currency RETURN @RESULT END

    Read the article

  • Looking for Visual SourceSafe trainers

    - by Trindaz
    Hi, Not exactly sure where this one should go, but I'm sure someone on SO knows a good Visual SourceSafe 2005 trainer based in the Sydney, Australia area who'd be happy to do a course at my company. Can anyone recommend someone? Or failing that, is there somewhere better I should be searching for this? Thanks in advance

    Read the article

  • Find the flaws in the concept...

    - by Trindaz
    A web based web browser. Sounds silly right? Here's a use case. All comments about what could go wrong, and if anyone has tried and failed at this, very much wanted User goes to www.theBrowser.com and logs in with credentials specific to theBrowser.com. User tells theBrowser what their username and password for various sites are User goes to theBrowser.com/?uri=somesite.com theBrowser sends off the http request with User's log in details, then sends the http response back to User. This lets theBrowser do weird and wonderful functions like change colours / style sheets / etc. to every site that gets passed through it. From a technical stand point, storing username and password and passing them along is not a challenge for one user, but if there were a few, I'd have to use some kind of server based browser software to store a session per user logged in at theBrowser.com. How could I do that? Will I have to start from scratch? Obviously privacy and security are issues. Would theBrowser.com be too great a risk, even if users are fully warned? Cheers, Dave

    Read the article

  • Regex validate dates like "Sun, 20 Jun 10"

    - by Trindaz
    Hi, I'm working on a regular expression that will only return true when a date string is in a format something like 'ddd, dd mmm yy'. Valid matches would be values like "Sun, 20 Jun 10" or "Mon, 21 Jun 10" but not "Sunday, 20 Jun 10" or "20 Jun 10". This will be used with mb_ereg in PHP. My attempts so far have only got me half way there. Any help appreciated! Thanks, Dave

    Read the article

1