如何在按钮后面传递文本并将其传递到文本框?像 "Preview"

How to pass a text behind a button and pass it to a text box? like a "Preview"

  1. 按钮里面有个小文字:

    private void TASKTOVSWRBTN_Click(object sender, EventArgs e)
    {
     Clipboard.SetText("The Network Operations Center is requesting a field engineer to attend the site in order to solve this issue. " +
        "\n Check carefully the hardware, cabling or passive network equipments, so the issue can be easily identified." +
        "\n If support is needed, please ring us, we will be here 24 / 7 to help.");
    
  2. 我想预览文本框内按钮后面的文字

  3. 将文本复制到剪贴板。

  4. 目前我只能从按钮复制​​到剪贴板。但我想在将文本发送到剪贴板之前查看文本,就像预览一样。

那就是:

private void TASKTOVSWRBTN_Click(object sender, EventArgs e)
{
    // "preview" the message in the textbox:
    bunifuMetroTextbox1.Text = "The Network Operations Center is requesting a field engineer to attend the site in order to solve this issue. " +
       "\n Check carefully the hardware, cabling or passive network equipments, so the issue can be easily identified." +
       "\n If support is needed, please ring us, we will be here 24 / 7 to help.";
}

private void btnGetIt_Click(object sender, EventArgs e)
{
    // if the textbox is not empty, then place its contents on the clipboard
    if (bunifuMetroTextbox1.Text.Trim().Length > 0)
    {
        Clipboard.SetText(bunifuMetroTextbox1.Text.Trim());
    }
}