So far that seems to have worked very nicely John. I started out by declaring a simple struct as a variable type at the top of the .cpp file above the WinMain function:

Code:
struct testStruct
{
    WCHAR name[MAX_STRINGLENGTH];
    int id;
};

...sometime later inside the WinMain function

testStruct struct1;
wcscpy_s(struct1.name, L"Struct_String"); //used the memory safe version of the string copy function
Then following the instructions on the link you sent me I made the CreateWindowEx function call like this:

Code:
HWND hWnd = CreateWindowExW(WS_EX_OVERLAPPEDWINDOW,
                               szWindowClass,
                               szTitle,
                               WS_OVERLAPPEDWINDOW,
                               CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, nullptr, nullptr, hInstance, &_struct);
Note the pointer at the end, the last argument. The window now has a pointer to my user made variable. Then inside the window message handler function I did this:

Code:
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
    static testStruct* pStruct;

    if (message == WM_CREATE)
    {
        CREATESTRUCT* pCreate = reinterpret_cast<CREATESTRUCT*>(lParam);

        pStruct = reinterpret_cast<testStruct*>(pCreate->lpCreateParams);
        SetWindowLongPtr(hWnd, GWLP_USERDATA, (LONG_PTR)pStruct);
    }
Not sure if the user variable needed to be declared as static but I sure only wanted it to ever be one thing so I declared it as static. AFAIK This now means the pointer has been set correctly, and is accessible outside of this function using the GetWindowLongPtr function.

Which is what happens below in the message handler for the dialogue box:

Code:
// Message handler for about box.
INT_PTR CALLBACK About(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
{
    LONG_PTR ptr = GetWindowLongPtr(GetParent(hDlg), GWLP_USERDATA);
    static testStruct* pStruct = reinterpret_cast<testStruct*>(ptr);
And finally the call that adds the string to the combo box entry further down in the dialogue box message handler:

Code:
switch (message)
    {
    case WM_INITDIALOG:        
        SendMessage(GetDlgItem(hDlg, IDC_COMBO1), CB_ADDSTRING, NULL, (LPARAM)pStruct->name);
        return (INT_PTR)TRUE;
Which gives the final result of this testing program:

How to access a structure from a message handling function-combo-box-1-jpg

Thanks very much for the link John

p.s. this has now all got much more windowsey than I first thought it would so perhaps the topic/thread should be moved.