|
This is an update of the early semi-official announcement that WTL will go "open source". MS has set up licensing (legal stuff) to make this happen... read more...
Microsoft toys with open source[^]
Unlike Microsoft's previous shared-source efforts, the WTL plan would allow non-Microsoft staff to be involved in managing and developing WTL.
While reluctant to reveal details, Mr Kumar said a key concern was to provide more support for developers so they did not have to keep using the Yahoo! forum.
Mike M
WinInsider.com
|
|
|
|
|
I'm having difficulty using ATL Server's CBlobCache class. I'm trying to add an entry to the blob cache. The key is "v1" and the value is an int. The add method takes a *void for the actual data, so I figured I could push an int into it. Unfortunately, the mout int reads 6,500,000 . Is it a problem with my implementation of m_spBlobCache->Add or m_spBlobCache->GetData ?
HCACHEITEM hEntry;
// Get the IMemoryCache service from the ISAPI extension
if (FAILED(m_spServiceProvider->QueryService(__uuidof(IMemoryCache),
&m_spBlobCache)))
return HTTP_FAIL;
HRESULT hr = m_spBlobCache->LookupEntry("v1", &hEntry);
if (FAILED(hr) || !hEntry)
{
static const int s7 = 1;
int *pData = (int *)malloc(sizeof(int));
if (!pData)
return HTTP_FAIL;
*pData = s7;
CFileTime ft = CFileTime::GetCurrentTime() + CFileTime::Minute;
if(FAILED(m_spBlobCache->Add("v1", pData, (DWORD)sizeof(int), &ft,
m_hInstHandler, &hEntry, &g_MemoryCacheClient)))
{
m_spBlobCache->ReleaseEntry(hEntry);
return HTTP_FAIL;
}
}
if(FAILED(m_spBlobCache->GetData(hEntry, (void**)&mout, &dwSize)))
{
m_spBlobCache->ReleaseEntry(hEntry);
return HTTP_FAIL;
}
TIA
Ryan
|
|
|
|
|
Stupid Me...
This code is correct, I just messed up the request handling part. Well, now if anyone wants to know how to write an int to CBlobCache, they can use this snippet...
Ryan
|
|
|
|
|
HI,
I am looking for atlstr.h header file.
Can anyone point to download from?
Thanks
|
|
|
|
|
|
Hi,
In MSDN, there is a desccription of the interface ISimpleFrameSite:
Containers can also support container controls without supporting ISimpleFrameSite, although the behavior cannot be guaranteed. For this reason, a component category exists for SimpleFrameSite controls where the full functionality of this interface is required.
To support container controls without implementing ISimpleFrameSite, an ActiveX control container must:
Activate all controls at all times.
Reparent the contained controls to the hWnd of the containing control.
Remain the parent of the container control.
Now I create a composite ActiveX control, Can I implement interface ISimpleFrameSite:, and how?
Thank you!
|
|
|
|
|
When right clicking on taskbar there is a sub menu :"toolbars"
Clicking here, shows a list of existing toolbars and "add new bar..."
Selecting this option shows a dialog where it is possiple to specify an URL pointing to a web page ie: http:www.nanana.com/button.htm
All this is manual ! and works fine and easy (only one parameter)
Is there a way (using VB or VBS) to create a deskband with a HTML content pointed by an URL.
This should look like : ...deskband.create url:="http:/...."
Obviously, there is a build in applet in the explorer that do the job a lot more simpler than creating 100% from scratch using ATL.
mailto:riberollesb@fsb.fr
|
|
|
|
|
hiya
I have a coclass that implements a dual interface (for use in C#), and I want to add a low level custom interface with the same methods for use by clients written in c++. But I have a couple of problems: firstly, C# picks the wrong method and refuses to compile unless I explicitly cast to the dual interface. Secondly, how do I implement methods from different interfaces with the same signature?
here's the code...
[<br />
object,<br />
uuid("32273BE2-CB15-47c2-BE09-DAA824A44916"),<br />
helpstring("IFuzzyLogic Interface"),<br />
pointer_default(unique),<br />
hidden<br />
]<br />
__interface IFuzzyLogic : IUnknown<br />
{<br />
[id(1), helpstring("method CreateModel")] HRESULT CreateModel([in] const char* szFileName, [out,retval] IFuzzyModel** ppModel);<br />
};<br />
<br />
[<br />
object,<br />
uuid("529A2190-6BB0-47A9-B1B4-001CD5981597"),<br />
dual, <br />
helpstring("IFuzzyLogicDual Interface"),<br />
pointer_default(unique)<br />
]<br />
__interface IFuzzyLogicDual : IDispatch<br />
{<br />
[id(1), helpstring("method CreateModel")] HRESULT CreateModel([in] BSTR sFileName, [out,retval] IFuzzyModelDual** ppModel);<br />
};
cheers,
Rob
|
|
|
|
|
Hi all,
Is WTL even available on MSDN/PlatformSDK anymore or is it really dead now ? I was planning on using it for a new app I'll be developing in VS.NET 2003, but I can't even find the SDK.
Thanks
|
|
|
|
|
|
I have an ATL project where I define several ATL COM objects. I would like to be able to create instances of these objects inside my module without having to use CoCreateInstance(). Everytime I try to do so it claims the classes are abstract because they do not define QueryInterface,AddRef...
Is there a way to create these objects internally without having to call CoCreateInstance?
Here's the logic to why I want to do this. I'm using a local class to catch some COM events. The local class implements a COM interface but itself is not a COM object. If I create this class with CoCreateInstance I will only be able to get the Event Sink interface back. The only way that I know of to call methods on this object would be to create a new interface for the object for the local methods I need. I would really like to avoid this. Here is a sample bit of code to show better what I'm trying to do
<br />
CEventSink : public _IEvents<br />
{<br />
public:<br />
void Setup(IEventSource *source);<br />
}<br />
<br />
...<br />
CEventSink sink;<br />
IEventSource *source;<br />
... CoCreatInstance for source...<br />
sink.Setup(source);<br />
Jared
jparsons@jparsons.org
www.prism.gatech.edu/~gte477n
|
|
|
|
|
|
|
I'm getting this error in ATL 7.0 trying to capture COM events from another library. I've researched this error on the web and it says to make sure you've included several header files. I've included all of hte header files
(atlbase,atlcom) and I've defined ATL_ATTRIBUTES above them. So far I've had no success in removing the error. Any ideas?
Jared
jparsons@jparsons.org
www.prism.gatech.edu/~gte477n
|
|
|
|
|
I fixed this problem in a hackish way. I created a new ATL project and copied all of the code over to the new project and it compiled fine.
The original project did not include ATL by default. I added it to the project settings later. The events suggest to me that in some way I failed to add ATL support properly. So what is the proper way to add ATL support to a project that formerly did not have it?
Jared
jparsons@jparsons.org
www.prism.gatech.edu/~gte477n
|
|
|
|
|
|
Array operations, like multiplying two arrays, is common in my work, and I therefore wrote a float array class, inheriting from STL-class vector. This approach slowed down the array multiplication with a factor of 150,(instantly back to the days of a 20 MHz computer, wiping out 20 years development!), if I compared it to multiplying two arrays created on the stack. Not using the vector template class, but still using a float array and functions defined inside a class, slows down multiplication with a factor of 15. What is the reason?
Bill
|
|
|
|
|
Probably the generation of extra copies of your matrix. Look in the net, there are a lot of implementations floating around. Also, I seem to remember an article in a fairly recent c++ users journal [^]
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
Hi,
I want to show line numbers on the left side of edit view. How to do that?
Thanks,
Derick.
|
|
|
|
|
Hi,
I'm witting an Outlook plugin in VC++, using ATL.
When a button in outlook is pressed, my plug-in will create a new mail, or reply to the selected one, or forward it. Now, the problem is that after generating this new window(for new mail, reply or fwd), when I close Outlook, another instance of Outlook remains somewhere running (I see it in Task Manager, and I have to close it form there). Any ideea what do wrong? Here is part of my code from the reply command:
for(int i=1; i<=lItemCount; i++)
{
CComPtr<IDispatch> spDisp;
CComVariant vt(i); //get selected item number i
hr = spSelection->Item(vt, &spDisp);
if(FAILED(hr))
return;
CComQIPtr< Outlook::_MailItem > spMailItem(spDisp);
CComPtr<Outlook::_MailItem> spMailItem2;
if(FAILED(hr))
return;
if(spMailItem!=NULL)
{
spMailItem->Reply(&spMailItem2);
BSTR subj;
spMailItem->get_Subject(&subj);
CString str = "Re:";
str += W2T(subj);
spMailItem2->put_Subject(T2W(str));
BSTR htmlBody;
spMailItem->get_HTMLBody(&htmlBody);
str = ReadHTMLIntoString((CString)W2T(bstrMSname)); //insert the Reply .html
str += "<br><br><br><i>Original text:</i><br><br>"; //something between our text and the original text
str += W2T(htmlBody);
htmlBody = T2W(str);
spMailItem2->put_HTMLBody(htmlBody);
spMailItem2->Display();
}
spMailItem2.Detach();
spMailItem.Detach();
spDisp.Detach();
}
I think something should be done with spMailItem2, but I just don't know what.
I would really appreciate any help.
Thanks,
Doru K
|
|
|
|
|
Hi there,
I am implementing connection points and i would like to know one thing here that is it possible to do custom marshalling with connection points.
My outgoing interface is something like this,
interface _INBDatabaseHandlerEvents
{
[helpstring("method RecieveBackupInfo")] HRESULT RecieveBackupInfo([in] BackUpInfo* bakupinfo);
}
where backupinfo is my own defined structue using multiple data types and they may not be automation compliant.
i have manually edited the coclass to
[default, source] interface _INBDatabaseHandlerEvents;
dispinterface removed and my object derives from IUnknown now.
QUESTION:
At the client side what should i do include .tlb or .h and .c for interfaces uuid.
And if provide only typelib information would it work if i have registered the proxy stub as well.
And i am just using the typelib to help the coz of not using .c and .h files from server
QUESTION:
how can i include .c file in different cpp for using cocreateinstance. It is not possible but i need the uuids for instantiating the objects.
Should i use typelib for custom interfaces with custom defined parameters it would make a difference or not.
Thanks in advance.
I'm looking forward for an urgent reply.
|
|
|
|
|
|
I'm following the MSDN ATL polygon tutorial. Anyways the control I want to port is nothing like the polygon control, but it'll due as a starting point. Basically I want to know if there is a way I can pass a large amount of data to the control?
Preferably I would like to pass text to the control using this method if possible.
<OBJECT>
Text from database would go here
</OBJECT>
If not, then even if I could pass large amounts text to the control via a PARAM tag inside the OBJECT???
Or am I going to have to use a JSCript method like AddText('Blah blah...')
Thans in advance
I'm drinking triples, seeing double and acting single
|
|
|
|
|
When i draw a contextmenu on my window, i dont receive any WM_COMMAND's when i click a menu option. Where should they go?
Thanks!
|
|
|
|
|