Click here to Skip to main content
15,890,123 members
Home / Discussions / COM
   

COM

 
QuestionActivedocument error - word addin problem Pin
K edar V18-Oct-06 20:07
K edar V18-Oct-06 20:07 
AnswerRe: Activedocument error - word addin problem Pin
K edar V18-Oct-06 20:25
K edar V18-Oct-06 20:25 
QuestionError while Installing Pin
Jeeva Mary Varghese18-Oct-06 19:26
Jeeva Mary Varghese18-Oct-06 19:26 
GeneralRe: Error while Installing Pin
prasad_som18-Oct-06 20:08
prasad_som18-Oct-06 20:08 
GeneralRe: Error while Installing Pin
Jeeva Mary Varghese18-Oct-06 20:50
Jeeva Mary Varghese18-Oct-06 20:50 
AnswerRe: Error while Installing Pin
Jonathan [Darka]19-Oct-06 23:38
professionalJonathan [Darka]19-Oct-06 23:38 
QuestionQustions about onLoad event!!!~~~~~thanks Pin
Armor Wei18-Oct-06 0:08
Armor Wei18-Oct-06 0:08 
QuestionUrgent : Regarding the delete w.r.t COM Pin
janadhana16-Oct-06 20:46
janadhana16-Oct-06 20:46 
Hi All,
I call a function fun()which is defined in X.dll .
the below is the code which is simillar to actual code.
when i execute i get as exception.

// sample.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"
#include "iostream.h"
#include "iomanip.h"
#include <algorithm>
#include <vector>

void fun(long **a);
int main(int argc, char* argv[])
{

long *amount = NULL;
fun(&amount);
long *ptr = amount;
for (int i = 0; i<5 ;++i,++ptr)
{
cout<< *ptr <<endl;
}
="" delete="" []amount;="" here="" i="" get="" an="" exception="" when="" try="" to="" delete.
="" return="" 0;
}

void="" fun(long="" **a)
{
="" *a="new" long[5];
=""
="" std::vector<long=""> var;
var.push_back(5);
var.push_back(6);
var.push_back(65);
var.push_back(58);
var.push_back(57);
std::vector<long>::iterator i;
int k = 0;
for(i= var.begin();i != var.end();++k, ++i)
{
(*a)[k] = *i;
}
}


the fun() is defined in the X.dll
Please let me know why i get an exception when i use delete []amount.
The same code works in the normal app, but when same mechanism is used in dll it does'nt work. the above code runs perfectly. i have the same code in the dll, the fun() is defined in the dll and the main() is in the application from which i use the interface to access the fun().

Thanks in advance..

Thanks & Regards,
Dhana

QuestionRe: Urgent : Regarding the delete w.r.t COM Pin
prasad_som16-Oct-06 21:20
prasad_som16-Oct-06 21:20 
AnswerRe: Urgent : Regarding the delete w.r.t COM Pin
janadhana16-Oct-06 22:24
janadhana16-Oct-06 22:24 
AnswerRe: Urgent : Regarding the delete w.r.t COM Pin
prasad_som16-Oct-06 22:36
prasad_som16-Oct-06 22:36 
GeneralRe: Urgent : Regarding the delete w.r.t COM [modified] Pin
Jörgen Sigvardsson18-Oct-06 9:07
Jörgen Sigvardsson18-Oct-06 9:07 
GeneralRe: Urgent : Regarding the delete w.r.t COM Pin
janadhana23-Oct-06 1:38
janadhana23-Oct-06 1:38 
AnswerRe: Urgent : Regarding the delete w.r.t COM Pin
User 21559716-Oct-06 23:10
User 21559716-Oct-06 23:10 
GeneralRe: Urgent : Regarding the delete w.r.t COM Pin
janadhana23-Oct-06 1:40
janadhana23-Oct-06 1:40 
QuestionConverting exe to com Pin
ashokvishnu16-Oct-06 17:59
ashokvishnu16-Oct-06 17:59 
AnswerRe: Converting exe to com Pin
Mike Dimmick17-Oct-06 0:09
Mike Dimmick17-Oct-06 0:09 
GeneralRe: Converting exe to com Pin
ashokvishnu17-Oct-06 0:58
ashokvishnu17-Oct-06 0:58 
GeneralRe: Converting exe to com Pin
mpk197917-Oct-06 21:22
mpk197917-Oct-06 21:22 
GeneralRe: Converting exe to com Pin
Mike Dimmick18-Oct-06 0:42
Mike Dimmick18-Oct-06 0:42 
GeneralRe: Converting exe to com Pin
mpk197918-Oct-06 20:17
mpk197918-Oct-06 20:17 
GeneralRe: Converting exe to com Pin
Mike Dimmick18-Oct-06 1:02
Mike Dimmick18-Oct-06 1:02 
GeneralRe: Converting exe to com Pin
ashokvishnu18-Oct-06 18:06
ashokvishnu18-Oct-06 18:06 
GeneralRe: Converting exe to com Pin
mpk197922-Oct-06 18:55
mpk197922-Oct-06 18:55 
Questionaccess controls Pin
vtalau16-Oct-06 17:51
vtalau16-Oct-06 17:51 

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.