I have a GUID variable and I want to write inside a text file its value. GUID definition is:
typedef struct _GUID { // size is 16 DWORD Data1;
printf(%X-%X-%X-%X-%X", guid.Data1, guid.Data2, guid.Data3, &guid.Data4);