Linked Questions

Popular Questions

CS1061 C# does not contain a definition for

Asked by At

help to understand what the error, thanks. Project write Universal Windows Platform (UWP) app, errors in XAML.

Error in line 61 case 6: // UserPage.xaml line 61 { this.RowHeaderMouseClick_dgvUsers = (global::Windows.UI.Xaml.Controls.Grid)(target); ((global::Windows.UI.Xaml.Controls.Grid)this.RowHeaderMouseClick_dgvUsers).Tapped += this.RowHeaderMouseClick; } break;

<Grid Grid.Column="0" x:Name="RowHeaderMouseClick_dgvUsers" Tapped="RowHeaderMouseClick">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
                <ColumnDefinition Width="1*" />
            </Grid.ColumnDefinitions>

code in c#

private void RowHeaderMouseClick_dgvUser(object sender, TappedRoutedEventArgs e)
    {
        Grid grd = sender as Grid;

        int rowIndex = Grid.GetColumn(grd);
        Grid.GetRow(grd);
        id_user.Text = dgvUsers.Text[0].ToString();
        first_name.Text = dgvUsers.Text[1].ToString();
        last_name.Text = dgvUsers.Text[2].ToString();
        email.Text = dgvUsers.Text[3].ToString();
        username.Text = dgvUsers.Text[4].ToString();
        password.Text = dgvUsers.Text[5].ToString();
        contact.Text = dgvUsers.Text[6].ToString();
        address.Text = dgvUsers.Text[7].ToString();
        gender.Text = dgvUsers.Text[8].ToString();
        user_type.Text = dgvUsers.Text[9].ToString();
    }

Related Questions