开发者

Transferring data from string into a Data View

I am trying to transfer data from a string to a Data View control, could someone demonstrate how this could be done:

 private void testing_Click(object sender, EventArgs e)
        {
            // Get a Sc开发者_如何学编程heduledTasks object for the computer named "DALLAS"
            string machineName = (@"\\" + System.Environment.MachineName);
            ScheduledTasks st = new ScheduledTasks(machineName);
            // Get an array of all the task names
            string[] taskNames = st.GetTaskNames();
            st.Dispose();
        }


for (int i = 0; i < taskNames.Count; i++)
{
    dataGridView1.Rows.Add(taskNames[i]);    
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜