Adjusting brightness with c++


How to convert the line below to C++.Net using Windows Form Application and to declare byte and data?
The original program was presented as "C#.Net Adjusting Brightness" (Author:Pantzmaster).

byte data = {Convert.ToByte(trackBar1.Value)};

Thank you

What is "trackBar1.Value" on your Arduino?

That code assumes that you have a windows form object named trackBar1. Do you?

It assumes that the trackBar1 object has a property called Value, with a method called getValue() backing it. Does it?