|
Hello,
I have Visual C++ program that implements Graphical User Interface (GUI). This program uses CWinApp, CFormView, CFrameWnd, and CDocument.
Now I need to package this C++ application to work as COM DLL (or ActiveX).
This program must be used as popup window from another program written in Java.
Is it possible to convert Visual C++ program with GUI into COM DLL or ActiveX ?
|
|
|
|
|
Hi all,
I have a problem in identifying which click was pressed.
Iam building two groups A and B.Each group contains one textbox and add button(all are builded dynamically).If i click on add button it should add textboxes to respective group.For add button click iam adding attributes and incrementing value from javascript using a hidden variable.
btnAddRange.Attributes.Add("onclick","javascript:submitVIN('"+GroupId+"')") this is code for click on a button.How can we identify click is performed on respective group.
Any help is greatly appreciated.
Thanks,
Vijaya
vijaya
|
|
|
|
|
which application it is??(MFC APP)
|
|
|
|
|
Hi,
I have a dll file that has implemented in framework 2.0 (VS 2005), but it has not used any advanced libraries. It is a vs2003 project, but have opened in VS2005. I have lost the code, what i have only the dll and now i want to add it to a vs2003 project. But it does not allow me to add it as a referrence. The problem is, it is a 2005 file.
Can I convert the dll to framework 1.1???????
Thanks in advanced!
jayasshc
|
|
|
|
|
Hi all.
I am having a problem passing a SAFEARRAY of IDispatch pointers to an outproc server. The problem occures when the outproc server goes to access one of IDispatch Interfaces method. The code work fine in inproc server.
Thanks in advance.
satindar
|
|
|
|
|
Hello satindar_kumar,
Make sure that the type library of the original interface (which contains the method that takes the SAFEARRAY of IDispatch pointers as parameter) is registered properly. Also make sure that the type library(ies) of each of the interfaces contained inside the SAFEARRAY is/are registered properly.
The type libraries must be registered because marshaling will definitely be required if the server is outproc.
In the case of inproc server, marshaling may not be needed hence the code worked fine. However, take note that if the interface is accessed cross-apartment, then marshaling will be required and hence the type libraries will need to be properly registered.
Hope the above helps,
Bio.
|
|
|
|
|
Good day. I am busy try to build an install for my project using WixEditor. I am struggling as this project has Dlls and one of these Dlls runs a CategoryInstaller that load Counter to a machine during the install. Can anyone point me to the right direction as to how to use Wix and how to reference DLLs and all, using Wix
Thanks
Kulile --- RSA
|
|
|
|
|
Did you mean a PerformanceCounterInstaller member?
WiX is the Windows Installer XML toolset. It doesn't really know much about what Visual Studio's deployment projects are up to. The .NET XxxInstaller classes seem to be intended for use with Visual Studio's deployment projects, which include Custom Action DLLs in your package which load the framework and run the Installer class.
WiX includes a performance counter custom action[^]. To use this, you need to create a .h and .ini file containing the descriptions of your performance counters. However, I don't know how to get this out of the Framework.
You may get a better answer by asking on the wix-users[^] mailing list.
|
|
|
|
|
Hello, everyone.
Please see below the description of a problem I met:
1. The Goal
The goal is to open the MS Excel document in read-only mode (so that it will be accessible for users while it is in use by my application). The access to the document is performed using COM. The application is written in VC++ using ATL.
2. The problem.
The "Open" method of the Workbooks object receives 13 parameters: the first is required (the path to the document), the others are optional.
The third parameter is ReadOnly, i.e. the parameter which controls the mode (r- or rw).
Therefore, to open a document in rw mode I have to pass only one (first parameter) - and it works fine.
But if I decide to open it in r- mode I will need to pass all 13 parameters. And here is there the problem occurs: I can not get IDispatch for a document if I pass all parameters.
Ok, I'm a not a lazy guy . I tried following options:
1) all parameters except 1-st and 3-d were passed as VT_EMPTY
2) all parameters except 1-st and 3-d were passed as VT_NULL
3) all parameters except 1-st and 3-d were initialized with the neutral values (which I got from the MS Excel Help for VB programming).
In all cases the result was the same: I got VT_EMPTY in the resulting VARIANT (please note, that the only thing I had to do, in order to open a document - change the number of parameters from 13 to 1).
Frankly speaking, I'm in the dark...
Have you ever met such problem? Could you please advice, where I'm wrong (since there is no doubt that I am)?
Your help is much appreciated. Thank you very much in advance.
|
|
|
|
|
I'm not sure which interface or method you're using, but since it looks like you're using a dispinterface I'd suspect the ReadOnly argument to be a VARIANT.
Try setting the ReadOnly argument to boolean type (VT_BOOL) and assign it VARIANT_TRUE or VARIANT_FALSE depending on you needs.
If it doesn't work, post again and describe what interface you're using and what methods you're calling.
Hope this helps
--
Roger
It's supposed to be hard, otherwise anybody could do it!
Regarding CodeProject: "resistance is pointless; you will be assimilated"
|
|
|
|
|
Hi,
Can anybody help me to get Icon details like its name, target path, working directory whenever it is double-clicked to run the application. This is be using Windows API or in C#.
I have already used IShellLink Interface but its been hard-coded for icon name. Suppose the user changes desktop icon name then also coding should be able to change its working directory. This can be done if I can check the existence of the icon.
Regards.
|
|
|
|
|
Help me on Creating a Crystal report using a predifined template with vc++ 6.0
I have tried so many times to create a new report using crystal report 11 by incorporating a template with vc++. I didnot find any article or sample code which is written in c++. But after some effort I got to know that there is a function called put_ReportTemplate() which is used for this task. I already know how to create a new report without using a template.
If anybody can help me by supplying a vc++ code on creating a Crystal report using a predifined template, it will be greatly appreciated.
Thanks.
SabseJugs
|
|
|
|
|
Hi
In com what does stub and proxy indicate?
I think proxy indicate interface file
class IComponent :public IUnknown; right?
What does stub mean?
Thanks.
|
|
|
|
|
In COM, if you create an object in-process you call interface methods directly on the actual object (well technically the object must be in the same apartment but ignore this for now). If the object you're talking to is further away, such as on another machine, this is obviously impossible. In cases like this, when direct a connection isn't possible, proxies and stubs come into play. A proxy is an object that implements the same set of interfaces as the real object and when its methods are called it sends, using whatever communication method is appropriate, information on which method was called and the parameters to the stub which is located near the real object. If the real object is on another machine the network will be used. The stub is an object that receives the data from the proxy and calls into the real object and the sends the return value and any out parameters back to the proxy and thus the client code. The MIDL compiler creates the proxy and stub for you (or info which enables the system to cook some up). Look up marshalling for more details.
Steve
|
|
|
|
|
|
((
fdsfkdsfkdsf
f
dsf
ds
f
dsf
sd
fsd
f
|
|
|
|
|
hi all i want to know,how to be notifid that internet exploer is attaching a file as mail attachment. or it is opening a common dialog box to attach the file basically i want to be notified for such a event, i had tried the Iwebbrowser2 but not found such a enent how to do that.
any ideas i welcomed.
actually i want to block the internet explorer to attach files i had done on hotmail and yahoo by getting the adress barname there was attach work in adress bar when attachement page was going to open, but in gmail adress bar does not changes it adress.
-- modified at 7:01 Thursday 31st August, 2006
Tasleem Arif
|
|
|
|
|
Have you seen this ?
HRESULT IWebBrowser2::put_Silent(VARIANT_BOOL bSilent)
you can suppress dialog boxes.
|
|
|
|
|
but how to be notified that internet explorer is had open common dialog box or it had clicked on what button or link is that is possible to know. i mean where the user had clicked i want to get that text caption or button caption is it possible?
-- modified at 0:44 Friday 1st September, 2006
Tasleem Arif
|
|
|
|
|
tasleem143 wrote: but how to be notified that internet explorer is had open common
If you set silent property, then no common dialog will be invoked,
tasleem143 wrote: i mean where the user had clicked i want to get that text caption or button caption is it possible?
I doubt how it is possible, because I think its altogether different mechanism.
Anyhow , whats problem setting this property, doesn't this solve your problem? You already able to get email page of respective accounts. You just need to set this property to true , once user goes to this page, and set back to false, after getting out of it.
|
|
|
|
|
can you guide me that on which event i should call this function i mean on DISPID_NAVIGATECOMPLETE2 OR behind some other thanks
|
|
|
|
|
hi all,
I am new to ATL|COM .
I have created a COM dll with a sinple function returning a string .
Now i want to access that function from my C++ Application.
Can anyone please help me to create an instance for this dll so that i can call that dll method.
A piece of sample code will be of great help.
Thanks in advance,
Veena.
|
|
|
|
|
Hope this helps you,
HRESULT hr = CoInitialize(NULL);
IMyInterface *pIMy;
if (SUCCEEDED(hr))
{
hr = CoCreateInstance(CLSID_CMyIterface,
NULL,
CLSCTX_INPROC_SERVER,
__uuidof(IMyInterface ),
(void **) &pIMy);
if (FAILED(hr))
{
CoUninitialize();
}
else
{
pIMy->MyFunction();
}
}
CoUninitialize();
|
|
|
|
|
do following steps
1. #import .tlb file in your client application. you will find this file in the folder of your com project.
2. Following code should solve your problem.I haven't done any error checking in following
code.
BSTR name;
CoInitialize( NULL );
IExpressionData* pOutputData = NULL;
hResult = CoCreateInstance(CLSID_CExpressionData //replace with your CLSID
, NULL
, CLSCTX_INPROC_SERVER
, IID_IExpressionData /replace with your IID_
, (void**)&pOutputData);
hResult = pOutputData->your_method( &name );
CoUninitialize( );
satindar
|
|
|
|
|
How can i run dos command using dotnet
for example: I want to run following command
Dir D:\*.*
now not only want to run that but the which ever result comes that i want to take in the dotnet windows form, i mean i want to print that result in the textbox OR if it should display directories in the listbox or some thing like that.
So is there any way to do that coz this is very urgent, please help me friends, u have helped me before this as well so please help me now as well
Harshad Pednekar
|
|
|
|