pass args into requestEvent

When use iic to communicate between boards, the function Wire.onRequest(requestEvent) of the slave board will be called when the master borad require message from the slave one, like that:
Wire.onRequest(requestEvent); // register event
void requestEvent()
{
Wire.write("hello "); // respond with message of 6 bytes
// as expected by master
}
BUT what should I do when I want pass args into requestEvent, like
Wire.onRequest(requestEvent); // register event
void requestEvent(String h)
{
Wire.write(h); // respond with message of 6 bytes
// as expected by master
}
I've tried in this way, but it seems doesn't work.
Wire.onRequest(requestEvent(h)); // register event

There are several mistakes in your code.

Wire.write() doesn't not expect String objects. If you must use the String class (I strongly suggest to avoid it) you must use the print() method.

The requestEvent handler gets a parameter but that's the size the master is requesting. You cannot send any number of bytes to the master but only exactly the number it requests.

I2C is not to be used as a replacement for the UART (hardware serial) interface!

If you have to provide information to the requestEvent handler you have to store that into global variables declared "volatile" (as the handler is called in interrupt context). Keep in mind that the handler is called when the master is requesting information and not when your slave is ready to send. So be prepared to send the requested content even if your slave doesn't have a valuable information.