Writing Hexdata to file

Can any one let me know a small function which write hexdata to file.
Suppose if i give input ffff,0x42..
Output should be written to file similar as input.

Use read/write. Remember to open the file as binary.
Topic archived. No new replies allowed.