cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
CChong
Level 11 Flexeran
Level 11 Flexeran

Can't set agent to use local notification server...?

I'm trying to point the agent at our local notification server, so I set the property DWUSHOST when I register the product code.

Ex :

// Create agent
THR(spAgent.CoCreateInstance(CLSID_Agent))

// Register product code/version
THR(spAgent->Register(bstrGuid, bstrVer))

// Disable scheduler
CComBSTR bstrName = _T("UseScheduler");
CComVariant vtVal = L"0";
THR(spAgent->put_value(bstrGuid, bstrName, vtVal))

// Set local notification server
bstrName = _T("DWUSHOST");
vtVal = _T("http://10.99.1.56");
THR(spAgent->put_value(bstrGuid, bstrName, vtVal))


Does this seem correct? If so, it doesn't seem to be working... the agent is still going out to the installshield notification server.

Thanks!
0 Kudos
(2) Replies
Christine_at_IS
Level 3

The keyword in the product ini file (which I think is what you are trying to set) is actually "Server". Also, if you are entering it directly into the product ini, you need to add a trailing forward slash to the pathurl.

So, the following would be valid:
// Set local notification server
bstrName = _T("Server");
vtVal = _T("http://10.99.1.56/");
THR(spAgent->put_value(bstrGuid, bstrName, vtVal))

However, we provide a method to do this directly:
SetHost
0 Kudos
CChong
Level 11 Flexeran
Level 11 Flexeran

Ohhh yeah, sorry. When I searched the help files for setting the local notification server I saw that other property and just assumed that was what needed to be set. I'll just use SetHost(), thanks.
0 Kudos