pass hex values as a parameter

Hello friends.
I need to pass some hex values as a parameter to a function like this

dataToSend(dataSent,0x51,0x6B,0x15);

On the implementation I do this

/*void dataToSend(byte *dataToSendArray,byte function, byte message1, byte message2)
{
dataToSendArray[2] = function;
dataToSendArray[3] = message1;
dataToSendArray[4] = message2;
dataToSendArray[5] = checkCrc(dataToSendArray);

When I try to compile it says

hexadecimal floating constants require an exponent[/quote
What I'm doing here wrong?

From the tiny snippet you have posted there I can see no logical cause for that error message.

However, you cannot find where to go on a map by staring at one tiny square of it.

Please post all your code so we can better see the context. If it is too big to post, please add it as an attachment.

Why do you need them to be in hex?

Arduino will treat them as 0s and 1s, you are not printing them in this function and even then you didn't have to use them in hex... so why the hex format?

What is dataSent? and checkCrc? Does checkCrc only work on 5 bytes? How does it know where to stop? Have you tried using decimal constants instead of hex?