To encode the message CRYPTOGRAPHY, write it in a block like this:
CRYP
TOGR
APHY
The coded message is read by looking at the columns, and writing them out like this: CTA ROP YGH PRY
To decode it, just write all the code words in a block again, as columns, and then read the message across the rows.