| Author |
Message |
|
ChopperLee
|
Post subject: Different between using public bool and public void in C#? Posted: Thu Feb 16, 2012 8:39 pm |
|
Joined: Thu Sep 29, 2011 4:18 pm Posts: 51
|
|
Can anyone tell me what is the different between using public bool and public void in C#?
For example:
what is the reason of using public void in below example ? public void updateDeviceSettings(int leftMeterSensitivity, int rightMeterSensitivity, int ledFadeOn, int ledFadeOff)
what is the reason of using public bool in below example ? public bool updateDevice(int leftMeterPercentage, int rightMeterPercentage,int ledRedValue, int ledGreenValue, int ledBlueValue, bool detachUsbOnButton)
|
|
 |
|
 |
|
nigelwright7557
|
Post subject: Re: Different between using public bool and public void in C Posted: Thu Feb 16, 2012 11:56 pm |
|
Joined: Thu Sep 22, 2011 2:35 am Posts: 77 Location: Carlisle England
|
|
With bool a true or false is returned by the procedure.
With void nothing is returned.
|
|
 |
|
 |
|
ChopperLee
|
Post subject: Re: Different between using public bool and public void in C Posted: Fri Feb 17, 2012 3:58 pm |
|
Joined: Thu Sep 29, 2011 4:18 pm Posts: 51
|
|
Thank for guiding Sir Simon Inns
|
|
 |
|
 |
|