Help modifying DS18B20 sample code to activate a relay

You need to change the return type of the print routine from void to float and add return tempC; at the bottom of the function.