Clarion 10/11 program running on Windows Server Core

server-os
Tags: #<Tag:0x00007f60c16147d8>

#1

Windows Server Core is windows server running with the “Desktop Experience”. This means there is no desktop, no file exporter, etc. Basically, you manipulate the server from a command prompt and powershell.
You can run a program with a UI like notepad and it works fine, so it doesn’t really mean no GUI. It means no built-in Windows GUI.

I wanted to run a nettalk server as a service on this type of Windows Server installation.
I found the program never launches, either from the command line as a non-service or running as a service.

I did some experimenting and this is what I found.

I have an old utility written in Clarion 5.5. This utility runs OK.
I wrote the following little program.


  PROGRAM


                              MAP
                                MODULE('Winapi')
                                  OutputDebugString(*CSTRING),PASCAL,RAW,NAME('OutputDebugStringA')
                                END
TestWindow                      procedure()

  END
TestString cstring('Hello world')
  CODE
  OutputDebugString(TestString)
  TestWindow()
  
TestWindow                    procedure()
MyWin                           WINDOW,AT(,,225,118)
                                  STRING('Hello word'),AT(43,39),USE(?STRING1)
                                END

  code
  open(MyWin)
  accept
  end
  close(MyWin)

This program works when compiled in LIB mode but fails when compiled in DLL mode. This is true even if I drop the TestWindow procedure so there is no window in the program at all. In that case I see the “hello world” message in debug view only when the program is compiled in LIB mode.

My conclusion at this point is there is some dependency in the Clarion runtime that does not exist in the Server Core installation.

Has anyone been able to get their Clarion 10/11 program to run under Server Core?


#2

Hi Rick - I wonder if dependency walker would run on that OS, to help test your hypothesis/conclusion.


#3

Very interesting comment. That’s exactly what Bob Z. just emailed me to try. :slight_smile:
With the idea of seeing what specific roles might be enabled on the server to get the needed files.


#4

cool. :slight_smile:

This page mentions another app called “dependencies.exe” that’s console based. If depends doesn’t work, maybe try this? https://stackoverflow.com/questions/49196859/how-to-output-dependency-walker-to-the-console


#5

Turns out oledlg.dll is the system DLL that is missing in the Server Core installation that the Clarion programs needs. Copying this file from \Windows\SYSWOW64 from a full installer of Windows Server to the same folder on the Server Core machine allows the Clarion program to run when compiled in DLL mode.
I don’t know the ramifications of doing this in a production environment or what happens with Windows Updates, so proceed with this knowledge at your own risk.