You've got the condtional operator the wrong way round. If guess is less than randomLetter then the letter you're looking for will be higher in the alphabet. Also I think you're making the task more compilcated by using strings when you're only guessing single characters -
Code:
#include <iostream>
#include <cstdlib>
#include <ctime>
using namespace std;
int main()
{
//declaration of variables
char randomLetter = 0;
char guess = 0;
//initialize the random number generator
srand(time(NULL));
//assign a the random value to number
randomLetter ='a'+ rand() % 26;
//get users guess
cout << "The computer has secretly picked a letter." << endl;
cout << "Try to guess the letter." << endl;
cout << "Your guess is: ";
cin >> guess;
guess = tolower(guess);
//repeat code till users guess is correct
while (guess != randomLetter)
{
//display higher or lower clue
if (guess > randomLetter)
cout << "The letter you are looking for is lower in the alphabet." << endl;
else
cout << "The letter you are looking for is higher in the alphabet." << endl;
//end ifs
cout << "Please try again!" << endl;
cout << "Your guess is: ";
cin>> guess;
guess = tolower(guess);
}//end while
cout << "That is correct!" << endl;
cout << " YOU WIN !!! " << endl;
return 0;
}// end of main function