How to save data to file?

I use fwrite(…); to save but it doesn’t work. In file is only one string - path of it file?

Any ideas?

This is not a openGL topic, my best advice for you is to learn C or C++ since fwrite function works perfectly, try to find some tutorials on google…