Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9151045
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T11:42:20+00:00 2026-06-17T11:42:20+00:00

I make some application with databinding in WPFToolkit:DataGrid. When I run the application, I

  • 0

I make some application with databinding in WPFToolkit:DataGrid.
When I run the application, I have catch this error, for example:

System.Windows.Data Error: 40 : BindingExpression path error:
‘ProcHandle’ property not found on ‘object’ ”ProcInfo’
(HashCode=61374531)’. BindingExpression:Path=ProcHandle;
DataItem=’ProcInfo’ (HashCode=61374531); target element is ‘TextBlock’
(Name=”); target property is ‘Text’ (type ‘String’)

In MainWindow.xaml:

<toolkit:DataGrid x:Name="DG1" ItemsSource="{Binding}" AutoGenerateColumns="False" Margin="0,47,0,0">
            <toolkit:DataGrid.Columns>
                <toolkit:DataGridTextColumn Header="Time/sec" Binding="{Binding KillTime}"/>
                <toolkit:DataGridTextColumn Header="Handle" Binding="{Binding ProcHandle}"/>
                <toolkit:DataGridTextColumn Header="Start Time" Binding="{Binding StartTime}"/>
                <toolkit:DataGridTextColumn Header="Status" Binding="{Binding ProcStatus}"/>
                <toolkit:DataGridTextColumn Header="Priority" Binding="{Binding ProcPriority}"/>
                <toolkit:DataGridTextColumn Header="End Time" Binding="{Binding EndTime}"/>
            </toolkit:DataGrid.Columns>
        </toolkit:DataGrid>

In MainWindow.xaml.cs

public partial class MainWindow : Window
    {
        private Process _firstProc;

        private DispatcherTimer _timerFirstProc;

        ProcessCollectionClass _procCollection = new ProcessCollectionClass();

        private int _firstProcTime;

public MainWindow()
        {
            InitializeComponent();
            DG1.DataContext = _procCollection.ProcCollection;
        }

        internal class ProcessCollectionClass : INotifyPropertyChanged
        {
            private ObservableCollection<ProcInfo> _procCollection = new ObservableCollection<ProcInfo>();

            public event PropertyChangedEventHandler PropertyChanged;

            public ObservableCollection<ProcInfo> ProcCollection
            {
                get { return _procCollection; }
                set
                {
                    _procCollection = value;
                    if (PropertyChanged != null)
                    {
                        PropertyChanged(this, new PropertyChangedEventArgs("ProcCollection"));
                    }
                }
            }
        }

        public class ProcInfo
        {
            public ProcInfo(string killTime, string procHandle, string startTime,
                            string procStatus, string procPriority)
            {
                KillTime = killTime;
                ProcHandle = procHandle;
                StartTime = startTime;
                ProcStatus = procStatus;
                ProcPriority = procPriority;
            }

            private string KillTime { get; set; }
            private string ProcHandle { get; set; }
            private string StartTime { get; set; }
            private string ProcStatus { get; set; }
            private string ProcPriority { get; set; }
        }

private void FirstProc_ButClick(object sender, RoutedEventArgs e)
        {

            _firstProcTime = Int32.Parse(FirstProcTime.Text);
            _firstProc = new Process();
            _firstProc.StartInfo.FileName = @"C:\Windows\System32\cmd.exe";
            _firstProc.StartInfo.UseShellExecute = true;
            _firstProc.Start();
            _firstProc.PriorityClass = ProcessPriorityClass.High;

            _timerFirstProc = new DispatcherTimer() { Interval = TimeSpan.FromSeconds(1) };
            _timerFirstProc.Start();
            _timerFirstProc.Tick += _timerFirstProc_Tick;
}
 void _timerFirstProc_Tick(object sender, EventArgs e)
        {
            --_firstProcTime;

            _firstProc.Refresh();
            _procCollection.ProcCollection.Add(new ProcInfo(
                                                   _firstProcTime.ToString(),
                                                   _firstProc.Handle.ToString(),
                                                   _firstProc.StartTime.ToString(),
                                                   _firstProc.Responding ? "Running" : "Not Responding",
                                                   _firstProc.PriorityClass.ToString()));

            if (_firstProcTime == 0)
            {
                _firstProc.Kill();
                _timerFirstProc.Stop();
            }
}

In the end I see only blank lines in DataGrid. What am I doing wrong!?
And sorry for my bad English

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T11:42:21+00:00Added an answer on June 17, 2026 at 11:42 am

    All your properties in the ProcInfo class are private. They should be public. Or at least have a public getter.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a windows application, where we make use IsolatedStorage to save some application
I have a Windows application in C#/.NET. I need to make some keyboard shortcuts
I just want to know that can i make an application which have some
I would like to make some request-wide data available in my app engine application.
I have developed a .net 3.5 c# web application and want to make some
I have created an application that does the following: Make some calculations, write calculated
My team has to make some changes and renew an old web application. This
I was trying to make some kind of help system for my application. QTextBrowser
I am using Windows application for my project. Now I want to make some
I want to make some changes to the stock Mms Android application and install

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.