Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. onlyshiza

    Passing an argument of type Byte from C++

    HI everyone, I am calling a VB COM dll server method from a C++ client. The VB method takes an argument of type Byte. It's defined as such: Public sub myAverage(ByVal rate as Byte) Now how I have to call this function from C++. After importing the dll into the C++ project the function is...
  2. onlyshiza

    Extracting a 2D-array from a COM server via SAFEARRAY

    Hi everyone, I am trying to extract 2 two-dimensinal arrays out of a COM server (a COM dll created in VB). The two dimensional array is the pixel information(1 byte info) of a 640 * 480 image. The tlb info shown in the MSVC++ object viewer tool is : HRESULT GetImages( [in, out]...
  3. onlyshiza

    Difference between Debug and Release executable?

    Agree with Lazy me. Most likely than not this is the memory problem, either trying to write a forbidden block of memory or reading that. check all your pointers array boundaries...
  4. onlyshiza

    CoCreateInstance

    Most likely one of the DLLs is not registered. So basically CoCreateInstance is looking for an interface in a COM dll that it cannot find. I think the dll registrations are not done properly during the installation (or maybe there is a bug there). I would reinstall the software. could you be...
  5. onlyshiza

    Constants in derived classes

    well, why you want to make that varible constant? As you said you are not able to change the value assigned to a constant, otherwise it wouldn't be constant anymore!...
  6. onlyshiza

    Changing the resolution of a laptop attached to a monitor

    thanks for the reply, Actually the ATI doesn't provide drivers for notebooks and it says get the drivers from the manufacturer of the notebook. Eventually I couldn't find any driver update for my video card from manufacturer site(sony) either.
  7. onlyshiza

    Passing a variant of type VT_INT as a function argument

    thanks for your reply Rick, Now I am using the VARIANT and setting the value of it from a SAFEARRAY like this: int tempArray[3]={1,0,0}; VARIANT var; VariantInit(&var); var.vt = VT_ARRAY | VT_INT; SAFEARRAY* pSafArr; SAFEARRAYBOUND safArrBnds = {3, 0}; pSafArr = SafeArrayCreate(VT_INT, 1...
  8. onlyshiza

    Changing the resolution of a laptop attached to a monitor

    Hi everyone, Maybe it's a dum question but when it comes to the hardware I am an absolute dummy :-) I have a sony laptop with "ATI Rage Mobility P/M AGP 2X(A21/2)" video card, the default lcd screen is broken(can't afford to fix it:-( ) so I use my laptop as a desktop and attach it...
  9. onlyshiza

    Passing a variant of type VT_INT as a function argument

    Hi everyone, I am calling a method in a COM dll that as the first parameter takes a VARIANT of type VT_INT (actually it has to be like a VARIANT array of (1,0,0), see the following code for more clarification). I am trying to make it work in C++. I have the equivalent working VB code which is...
  10. onlyshiza

    Passing a variant of type VT_INT as a function argument

    Hi everyone, I am calling a method in a COM dll that as the first parameter takes a VARIANT of type VT_INT (actually it has to be like a VARIANT array of (1,0,0), see the following code for more clarification). I am trying to make it work in C++. I have the equivalent working VB code which is...
  11. onlyshiza

    Trouble with VC++ compiler

    I think this has happened to all of us :-) i was not able to figure out what the problem was in most cases, however in one case I noticed the reason was that the clock of my computer was not correct, so the timestamp of the file with changes is different from the internal clock and the compiler...
  12. onlyshiza

    'calling convention' conflict in calling fucntions from a com dll

    Hi everyone, I am writing a VC++6.0 client for a com dll(developed in VB6.0). I have a problem calling some functions of the dll, the error message I get is: "The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one...
  13. onlyshiza

    return a safearray as a variant from a COM objects

    Hey, sorry man, I overlooked that you are using CCOMSafeArray. This is new to ATL 7.0 and I am not very familiar with it, there are no wrapper classes in ATL 3 for safearrays. :-)However might find some hints on this link...
  14. onlyshiza

    return a safearray as a variant from a COM objects

    Hi Dave, For the safearrays you should use - Use SafeArrayCreate() to create the array and - Use SafeArrayAccessData() to gain access to the array’s data elements otherwise you most likely run into memory problems as you did. if you have access to MSDN get some more info on these. Hope this...
  15. onlyshiza

    'calling convention' conflict in calling fucntions from a com dll

    Thanks for you reply Rick, Here is the tlb information of the method I am calling: [id(0x60030009), helpstring("Retrieve the marker's description from the persistence file and checks the template's validity. If it returns a value other than mtSuccess, an explanation (in English)...
  16. onlyshiza

    'calling convention' conflict in calling fucntions from a com dll

    Hi everyone, I am writing a VC++6.0 client for a com dll(developed in VB6.0). I have a problem calling some functions of the dll, the error message I get is: "The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one...
  17. onlyshiza

    'calling convention' conflict in calling fucntions from a com dll

    Hi everyone, I am writing a VC++6.0 client for a com dll(developed in VB6.0). I have a runtime problem calling some functions of the dll, the error message I get is: "The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared...
  18. onlyshiza

    Availablity of pointer to interface via importlib in IDL

    Hi everyone, It's a few days now that I have searched this site as well as lots of other sites, couldn't resolve my problem yet. I try to make it brief: -Background: I am creating a C++ client for a COM component written in VB. The COM developer has provided me with the dll and the IDL file. I...

Part and Inventory Search

Back
Top