PDA

Просмотр полной версии : [Помогите!] из label в numericUpDown


StabiliZator
08.06.2011, 18:12
как сделать что бы выводилось то число в (label) которое ввел в numericUpDown

_MykytiuK_
08.06.2011, 18:48
Кажись так:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Net;
using System.Threading;
using System.IO;

namespace WindowsFormsApplication32
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}

private void label1_Click(object sender, EventArgs e)
{
}

private void numericUpDown1_ValueChanged(object sender, EventArgs e)
{
label1.Text = Convert.ToString(numericUpDown1.Value);
}

}
}

Hermein
09.06.2011, 17:47
private void numericUpDown1_ValueChanged(object sender, EventArgs e)
{
label1.Text = numericUpDown1.Value.ToString();
}