text file as resource?
Does anyone know if you can add a text file as a win32 resource? If so, how
would I load the text file from the resource?
Hi,
You can add the text file (or whatever file in fact) in the resource file using user defined resources.
To load this resource in your code, use:
It is not necessary to unlock the resource after that.
HTH,
You can add the text file (or whatever file in fact) in the resource file using user defined resources.
To load this resource in your code, use:
HRSRC hrsrc = FindResource(NULL, my_name, my_user_type);HGLOBAL hresdata = LoadResource(NULL, hrsrc);char *pText = (char *)(LockResource(hresdata);
It is not necessary to unlock the resource after that.
HTH,
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement