Solved

Convert a byte to an Int

Posted on 2011-03-04
2
431 Views
Last Modified: 2012-05-11
Hi all,

I'm having a small (I hope) problem.

Can someone tell me how to convert a byte to its int value?

I have a method from a 3rd party object which returns the LCD brightness value of its screen. Its a value between 0 and 100. The documentation shows that the return value is a single byte.

How do I convert this byte value to its integer value?

byte b = ti.LcdBrightness;

Thanks,

Sunny
0
Comment
Question by:Sunny_Kumar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
ID: 35037361
Int32 i = Convert.ToInt32(b);
0
 
LVL 1

Author Closing Comment

by:Sunny_Kumar
ID: 35037421
Thanks, I was thinking far too complicated!
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In order to hide the "ugly" records selectors (triangles) in the rowheaders, here are some suggestions. Microsoft doesn't have a direct method/property to do it. You can only hide the rowheader column. First solution, the easy way The first sol…
Introduction Although it is an old technology, serial ports are still being used by many hardware manufacturers. If you develop applications in C#, Microsoft .NET framework has SerialPort class to communicate with the serial ports.  I needed to…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question