Hi,
You can find an example for the Ethernet TCP with the K64 at its SDK driver examples. You can download the SDK at the following link, where you will have to select the FRDMK64F board, and then the software components you would like to have: https://mcuxpresso.nxp.com/en/select. The following image show you what you should see before downloading the SDK (In my case, I've selected all the software components).

When you open MCUXpresso, you just have to:
1) Drag the downloaded compressed file at the "Installed SDKs".
2) Click on "Import SDK example" where you will select the K64 board.
3) Search and select the Ethernet TCP example.

Best Regards,
Ricardo Delsordo.