Click here to Skip to main content
15,892,480 members
Home / Discussions / COM
   

COM

 
QuestionIdentifying Dynamic Controls click Pin
vijayaBTS5-Sep-06 0:52
vijayaBTS5-Sep-06 0:52 
GeneralRe: Identifying Dynamic Controls click Pin
voorugonda prashanth6-Sep-06 0:51
voorugonda prashanth6-Sep-06 0:51 
QuestionDLL Conversion to 2005 to 2003 Pin
Charith Jayasundara4-Sep-06 7:13
Charith Jayasundara4-Sep-06 7:13 
QuestionError while accssing methods of interfaces passed in safearray Pin
satindar_kumar4-Sep-06 0:56
satindar_kumar4-Sep-06 0:56 
AnswerRe: Error while accssing methods of interfaces passed in safearray Pin
Lim Bio Liong10-Sep-06 5:37
Lim Bio Liong10-Sep-06 5:37 
QuestionWix Editor Pin
kulile3-Sep-06 23:39
kulile3-Sep-06 23:39 
AnswerRe: Wix Editor Pin
Mike Dimmick6-Sep-06 1:06
Mike Dimmick6-Sep-06 1:06 
QuestionOpening MS Excel document in "read only" mode Pin
Roaming Clone3-Sep-06 20:05
Roaming Clone3-Sep-06 20:05 
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 Wink | ;-) . 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.
AnswerRe: Opening MS Excel document in "read only" mode Pin
Roger Stoltz4-Sep-06 5:36
Roger Stoltz4-Sep-06 5:36 
QuestionIcon information?? Pin
Sgg2453-Sep-06 19:27
Sgg2453-Sep-06 19:27 
QuestionVery urgent (plz solve) Pin
SabseJugs3-Sep-06 17:54
SabseJugs3-Sep-06 17:54 
Questionwhat is the meaning of proxy/stub Pin
sawerr1-Sep-06 10:28
sawerr1-Sep-06 10:28 
AnswerRe: what is the meaning of proxy/stub Pin
Stephen Hewitt1-Sep-06 16:57
Stephen Hewitt1-Sep-06 16:57 
GeneralRe: what is the meaning of proxy/stub Pin
sawerr1-Sep-06 19:36
sawerr1-Sep-06 19:36 
Questionerror Pin
Itanium31-Aug-06 6:32
Itanium31-Aug-06 6:32 
Questionbrowser monitering [modified] Pin
_tasleem31-Aug-06 0:44
_tasleem31-Aug-06 0:44 
AnswerRe: browser monitering Pin
prasad_som31-Aug-06 3:12
prasad_som31-Aug-06 3:12 
GeneralRe: browser monitering [modified] Pin
_tasleem31-Aug-06 5:03
_tasleem31-Aug-06 5:03 
AnswerRe: browser monitering Pin
prasad_som31-Aug-06 19:01
prasad_som31-Aug-06 19:01 
GeneralRe: browser monitering Pin
salman kazi31-Aug-06 19:05
salman kazi31-Aug-06 19:05 
QuestionHow to create an ATL\COM dll object in a C++ Client Application? Pin
veenu_kvm30-Aug-06 19:59
veenu_kvm30-Aug-06 19:59 
AnswerRe: How to create an ATL\COM dll object in a C++ Client Application? Pin
prasad_som30-Aug-06 23:33
prasad_som30-Aug-06 23:33 
AnswerRe: How to create an ATL\COM dll object in a C++ Client Application? Pin
satindar_kumar30-Aug-06 23:40
satindar_kumar30-Aug-06 23:40 
QuestionHow to run Dos Command in Dotnet witout opening Command Prompt Pin
Harshad Pednekar29-Aug-06 23:55
Harshad Pednekar29-Aug-06 23:55 
GeneralRe: How to run Dos Command in Dotnet witout opening Command Prompt Pin
prasad_som30-Aug-06 3:00
prasad_som30-Aug-06 3:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.