Yes, you can, but only if your PC soundcard has an optical output. This is usually a square port or it might be a round mini-jack type opening.
You can use the supplied optical cable if it's the first type, or you will need to buy an adaptor (eg. from Maplins) for the second type.
If you don't have an optical output then you can still record, but you will need a stereo line lead connected to a headphone or line-out jack.