Awesome, thanks, I got the SDK compiling OK with the express edition. I'm still getting errors with the wsh panel code though:
Compiling...
main.cpp
.\main.cpp(760) : error C2065: 'IActiveScriptParsePtr' : undeclared identifier
.\main.cpp(760) : error C2146: syntax error : missing ';' before identifier 'parser'
.\main.cpp(760) : error C2065: 'parser' : undeclared identifier
.\main.cpp(766) : error C2065: 'parser' : undeclared identifier
.\main.cpp(769) : error C2065: 'parser' : undeclared identifier
.\main.cpp(769) : error C2227: left of '->InitNew' must point to class/struct/union/generic type
type is ''unknown-type''
.\main.cpp(773) : error C2065: 'parser' : undeclared identifier
.\main.cpp(773) : error C2227: left of '->ParseScriptText' must point to class/struct/union/generic type
type is ''unknown-type''
Any idea what's gone wrong? I assume it's just something to do with 'IActiveScriptParsePtr', if that line worked maybe the others would too. I found an entry on msdn for the error: http://msdn.microsoft.com/en-us/library/ewcf0002(VS.80).aspx, and I would guess my problem is no. 2: "You may be calling a function in an SDK header file that is currently not supported in your build environment", so the question is, how do I fix my build environment...? I just did some more googling and IActiveScriptParse is mentioned on msdn, but IActiveScriptParsePtr isn't... maybe I should try it without the Ptr on the end. Don't know if that's a good idea though...
Any help much appreciated!
For reference the problematic bit of code is this:
HRESULT _script_init(){
HRESULT hr = script_term();
IActiveScriptParsePtr parser;
IActiveScriptSitePtr site;
pfc::stringcvt::string_wide_from_utf8 u_name, u_code;
u_name.convert(m_script_name, m_script_name.length());
u_code.convert(m_script_code, m_script_code.length());
if(SUCCEEDED(hr)) hr = m_engine.CreateInstance( (OLECHAR*)(const wchar_t*) u_name );
if(SUCCEEDED(hr)) hr = m_engine->QueryInterface(&parser);
if(SUCCEEDED(hr)) site.Attach(new ScriptSite(this), true);
if(SUCCEEDED(hr)) hr = m_engine->SetScriptSite(site);
if(SUCCEEDED(hr)) hr = parser->InitNew();
if(SUCCEEDED(hr)) hr = m_engine->AddNamedItem(L"window", SCRIPTITEM_ISVISIBLE | SCRIPTITEM_ISSOURCE);
if(SUCCEEDED(hr)) hr = m_engine->AddNamedItem(L"gdi", SCRIPTITEM_ISVISIBLE | SCRIPTITEM_ISSOURCE);
if(SUCCEEDED(hr)) hr = m_engine->AddNamedItem(L"fb", SCRIPTITEM_ISVISIBLE | SCRIPTITEM_ISSOURCE);
if(SUCCEEDED(hr)) hr = parser->ParseScriptText( (OLECHAR*)(const wchar_t*) u_code, NULL, NULL, NULL, NULL, 0, 0, NULL, NULL);
if(SUCCEEDED(hr)) hr = m_engine->SetScriptState(SCRIPTSTATE_CONNECTED);
if(SUCCEEDED(hr)) hr = m_engine->GetScriptDispatch(NULL, &m_script_root);
return hr;
}