load string from stringtable inside a windows service

Tech-Archive recommends: Speed Up your PC by fixing your registry



I am using a windows service and am calling an mfc function which
writes to log. The function is inside another MFC App project. Inside
that function i am loading a string from stringtable and writing it to
the logfile. The issue is that the string is not getting written to
the log. If before writing to the log, i display the string in
messagebox, it shows up correctly. but its not showing in the log
file.

In DLL we do a AFX_MANAGE_STATE(AfxGetStaticModuleState()). Do we have
to do that in service also?
Can anyone tell why this is happening?

Thanks,
Rohit
.



Relevant Pages

  • Windows service
    ... I am writing a windows service application. ... string value when asked by external program. ...
    (microsoft.public.dotnet.general)
  • Reading Registry Values
    ... I have been attempting to update a Windows Service that was written a couple years ago. ... Private Function GetRegKey(ByVal Item As String, Optional ByVal NoValRet As String = "") As String ... Dim Result As String = "" ... I run it on the production box, I get "", and both have the EXACT same registry setup and values. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Debugging a Windows Service
    ... Windows Service In General Hint: ... Exception e = args.ExceptionObject as Exception; ... string exceptionLogDirectory = string.Empty; ... I'm writing a windows service, that uses a WCF service (the server ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: threading question
    ... >I have the following code in a windows service, ... > string InternalTransactionID=""; ... > strH= objP.ConvertNewCt(data,out InternalTransactionID);> ...
    (microsoft.public.dotnet.languages.csharp)
  • CRC checksum algorithm
    ... I’m working with handheld device that communicates with windows service thru ... Transaction between device and my application looks like this: ... As you see at the end of the string, after DLE ETX (Data Link escape and end ... this would be the calculation of CRC checksum of this ...
    (microsoft.public.dotnet.languages.vb)