I got this project im working on, where when I save something to the clipboard it stores it in a textbox and then waits until I save something else and then stores that value in the textbox aswell..
Its working perfectly but I want to make it even better, because I currently have a timer as a loop that checks if the current value has been used or not (see my code below)
And I wanted to change it to where I can just compare a variable with a string, but I dont really know how to.
I tried this.. But I didnt know what to compare it too SO I couldnt move any further. var containData = Clipboard.GetText();
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace CBR
{
    public partial class mainFrm : Form
    {
        public mainFrm()
        {
            InitializeComponent();
        }
        private void mainFrm_Load(object sender, EventArgs e)
        {
        }
        #region ButtonsAndTimer
        private void clipboardUpdater_Tick(object sender, EventArgs e)
        {
            if (!clipboardSaveTextBox.Text.Contains(Clipboard.GetText()))
            {
                clipboardSaveTextBox.Text += "\n" + Clipboard.GetText();
            }
        }
        private void monitorButton_Click(object sender, EventArgs e)
        {
            clipboardUpdater.Enabled = true;
        }
        private void stopMonitorButton_Click(object sender, EventArgs e)
        {
            clipboardUpdater.Enabled = false;
        }
        #endregion
    }
}
 
     
    