Click here to Skip to main content
15,909,518 members
Home / Discussions / WPF
   

WPF

 
GeneralRe: Slower WPF Performance after a button gets focus Pin
Mark Salsbery19-Dec-08 4:52
Mark Salsbery19-Dec-08 4:52 
GeneralRe: Slower WPF Performance after a button gets focus Pin
Jammer19-Dec-08 0:19
Jammer19-Dec-08 0:19 
QuestionPrint in WPF Pin
VisualLive17-Dec-08 17:40
VisualLive17-Dec-08 17:40 
AnswerRe: Print in WPF Pin
Fabio V Silva17-Dec-08 23:43
Fabio V Silva17-Dec-08 23:43 
AnswerRe: Print in WPF Pin
elektrowolf18-Dec-08 1:05
elektrowolf18-Dec-08 1:05 
AnswerRe: Print in WPF Pin
Thomas Stockwell22-Dec-08 6:28
professionalThomas Stockwell22-Dec-08 6:28 
QuestionWPF & DELL Tablet PC Pin
Jammer17-Dec-08 7:01
Jammer17-Dec-08 7:01 
QuestionWPF Databinding : Cannot bind data Pin
Arijit Manna17-Dec-08 2:59
Arijit Manna17-Dec-08 2:59 
Hello

Iam trying to run a WPF application, but no data is dsplayed in the Grid.
The relevant codebehind file is as under Window1.xaml.vb

Private Sub BindData()

           Dim conn As SqlConnection = New SqlConnection
           Dim command As SqlCommand
           Dim dataadp As SqlDataAdapter = New SqlDataAdapter
           Dim dtTbl As Data123DataSet = New Data123DataSet
           Dim query As String = "SELECT EntityCode, Title, Name FROM dbo.Entity"
           Dim connstring As String = "Data Source=SRITANU;Initial Catalog=Data123;User ID=sa"
           conn = New SqlConnection(connstring)

           Try
               command = New SqlCommand(query, conn)
               conn.Open()
               dataadp.SelectCommand = command
               dataadp.Fill(dtTbl, "Entity")
               DataContext = dtTbl
           Catch ex As Exception
               conn.Close()
           End Try

       End Sub

The XAML code is as under Window1.xaml :
<Window x:Class="Window1"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="Window1" Height="300" Width="670" xmlns:c1grid="http://schemas.componentone.com/wpf/C1DataGrid" WindowState="Maximized">
    <Grid Width="574">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="574*" />
            <ColumnDefinition Width="0*" />
        </Grid.ColumnDefinitions>
        <c1grid:C1DataGrid Margin="0,12,0,21" DataContext="{Binding dtTbl}"  Name="C1DataGrid1" ItemsSource="{Binding Path=Data123DataSet.dtTbl, ElementName= Window, Mode=Default}">
            <c1grid:C1DataGrid.Columns>
                <c1grid:Column Caption="CUSTID" ColumnName="EntityCode" PropertyName="EntityCode " />
                <c1grid:Column Caption="TITLE" ColumnName="Title" PropertyName=" Title"/>
                <c1grid:Column Caption="NAME" ColumnName="Name" PropertyName=" Name"/>
            </c1grid:C1DataGrid.Columns>
        </c1grid:C1DataGrid>
    </Grid>
</Window>


Please point out my mistake. Iam quite befuddledConfused | :confused:

Best Wishes ....... ARIJIT

AnswerRe: WPF Databinding : Cannot bind data Pin
Mark Salsbery17-Dec-08 6:33
Mark Salsbery17-Dec-08 6:33 
GeneralRe: WPF Databinding : Cannot bind data Pin
Arijit Manna17-Dec-08 18:50
Arijit Manna17-Dec-08 18:50 
GeneralRe: WPF Databinding : Cannot bind data Pin
Arijit Manna17-Dec-08 18:51
Arijit Manna17-Dec-08 18:51 
GeneralRe: WPF Databinding : Cannot bind data Pin
Mark Salsbery18-Dec-08 8:16
Mark Salsbery18-Dec-08 8:16 
QuestionHow to binding to the actual width and height of the control in doubleanimation? Pin
Eric Vonjacson16-Dec-08 23:20
Eric Vonjacson16-Dec-08 23:20 
AnswerRe: How to binding to the actual width and height of the control in doubleanimation? Pin
Pete O'Hanlon17-Dec-08 3:41
mvePete O'Hanlon17-Dec-08 3:41 
GeneralRe: How to binding to the actual width and height of the control in doubleanimation? Pin
Eric Vonjacson17-Dec-08 18:54
Eric Vonjacson17-Dec-08 18:54 
GeneralRe: How to binding to the actual width and height of the control in doubleanimation? Pin
Pete O'Hanlon17-Dec-08 22:04
mvePete O'Hanlon17-Dec-08 22:04 
QuestionUnable to open the Wpf application in windows ( SCSF) [modified] Pin
kinnuP16-Dec-08 23:01
kinnuP16-Dec-08 23:01 
QuestionNEW reporting tool for Silverlight. Pin
TechiGIRL16-Dec-08 22:45
TechiGIRL16-Dec-08 22:45 
Questioncode for email registration and confirmation Pin
harikrishna25116-Dec-08 22:22
harikrishna25116-Dec-08 22:22 
AnswerRe: code for email registration and confirmation Pin
Michael Sync29-Jan-09 2:46
Michael Sync29-Jan-09 2:46 
Questionemail registration and confirmation project Pin
harikrishna25116-Dec-08 22:18
harikrishna25116-Dec-08 22:18 
AnswerRe: email registration and confirmation project Pin
Vimalsoft(Pty) Ltd21-Dec-08 20:53
professionalVimalsoft(Pty) Ltd21-Dec-08 20:53 
Questionmissing taglistenUriMode="Explicit/Unique" Pin
vikramsc16-Dec-08 3:35
vikramsc16-Dec-08 3:35 
QuestionRe: missing taglistenUriMode="Explicit/Unique" Pin
Mark Salsbery16-Dec-08 5:42
Mark Salsbery16-Dec-08 5:42 
AnswerRe: missing taglistenUriMode="Explicit/Unique" Pin
Pete O'Hanlon16-Dec-08 8:31
mvePete O'Hanlon16-Dec-08 8:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.