IR temperature sensor and LCD

I have blended the IRtemp sketch (freetronics) and the LiquidCrystal Sketch but I cant seem to get the screen to just show the change in temperature only.

/*

*/

#include "IRTemp.h"
#include "LiquidCrystal.h"

LiquidCrystal lcd(12, 11, 9, 8, 7, 6);

static const byte PIN_DATA = 2; // Choose any pins you like for these
static const byte PIN_CLOCK = 3;
static const byte PIN_ACQUIRE = 4;

static const TempUnit SCALE=CELSIUS; // Options are CELSIUS, FAHRENHEIT

IRTemp irTemp(PIN_ACQUIRE, PIN_CLOCK, PIN_DATA);

void setup() {
lcd.begin(16, 2);
// initialize the serial communications:
Serial.begin(9600);
}

void loop() {
// when characters arrive over the serial port...
if (Serial.available()) {
// wait a bit for the entire message to arrive
delay(100);
// clear the screen
lcd.clear();
// read all the available characters
while (Serial.available() > 0)
{
// display each character to the LCD
lcd.write(Serial.read());
}

{
float irTemperature = irTemp.getIRTemperature(SCALE);
printTemperature("IR", irTemperature);
}
{
float ambientTemperature = irTemp.getAmbientTemperature(SCALE);
printTemperature("Ambient", ambientTemperature);

delay(1000);
}
{
void printTemperature(char *type, float temperature)

Serial.print(type);
Serial.print(" temperature: ");

if (isnan(temperature)) {
Serial.println("Failed");
}
else {
Serial.print(temperature);
Serial.println(SCALE == FAHRENHEIT ? " F" : " C");
}
}

It looks like the only characters displayed on the LCD are the characters received from Serial. If you want to display the change in temperature on the LCD you should calculate that value and use lcd.print(value) to display it on the LCD.

The code you posted won't even compile.

Put EVERY { on a new line.

Use Tools + Auto Format to fix the indenting, after you have added the correct number of }. Then, get rid of the useless curly braces.

The printTemperature() is a useless function, since it does nothing with the LCD.

when I get rid of print temperature as you suggest I get nothing on the screen. The code compiles in the newest iteration of the Arduino software but, as you say, it has flaws. It seems to want to print across the screen almost like scrolling but in slo-mo. Moves one space across. fades. moves one space across and as it moves it reenters so you get 1.21 on one side and temp: 21.21 in the middle and 2 on the outside and the positions change. Whats the issue in the code?

Whats the issue in the code?

You made some changes (or you are wasting our time). You didn't post the changed code.

I'm going to guess (I left my crystal ball in my other pants) that the problem is line 37.