|
hi Zac,
Thanks for ur reply..
I am using dll of the activex control.I give its classId in <object> in HtmlPage(IE).
So whenver i open the IE page,Activex control Dll is downloded and then player starts downloading cam file and plays it.
So if i again open IE page,a new instance is instantiated and new player opens.This player uses the same Dll and starts downloading the cam file.
The problem is,as soon as 2nd player opens,the first player is crashing.
Any solution for this..
Thanks in advance
sunita
|
|
|
|
|
Can you explain how you to use your activex
whitesky
|
|
|
|
|
Hi,
If I have classes like this
class A
{
virtual void fun();
void gun(int);
int i, j;
}
class B : public A
{
virtual void fun1();
virtual void fun();
void gun(int);
virtual void run(int);
int i, j;
}
main()
{
A a;
B b;
}
Now how many vtable will create here.
-- modified at 2:17 Monday 17th July, 2006
|
|
|
|
|
Where is the class B?
If you have mistyped it , it should be like
class B:public A
Then In this case two VTABLEs will be created one for each class .
A VTABLE is created for each class containing a virtual function and for each of the class that is derived from it.
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
Hi Anshuman,
In this case, how many v-tables will be crated? (Means, the derived class doesn't have its own virtual fn.s.)
class A
{
virtual void fun();
void gun(int);
int i, j;
}
class B : public A
{
void gun(int);
int i, j;
}
Thanks in advance,
Sarvan AL
|
|
|
|
|
In this example only one vtable will be created which (ignoring RTTI) will contain a pointer to the single virtual function A::fun . The constructor (implicitly generated by the compiler) will set the vtable pointer in class A's instance data to point to this table. If B had overridden this method then there would be another vtable for class B and B's constructor would replace the vtable pointer (set in A) with a pointer to B's vtable.
Steve
|
|
|
|
|
how to close all child windows in MDI?
like the VC->windows->Close All
|
|
|
|
|
use AfxGetApp()->CloseAllDocuments(FALSE)
|
|
|
|
|
Hi everyone, i need to resize an image(sizes vary) to a thumbnail so that i can add it to an image list for a list box, what is the best way to do it.... any help would be much appreciated.
the image list and the list box work fine, but i am unable to resize the image. so when it is displayed you just see the top left hand corner of the image.
Thanks in advance
Lee
|
|
|
|
|
You have to create a thumbnail image by your self. Here is the code snippet for that
//lets say your original image is in BitmapOrg
BITMAP BmpInfo;
BitmapOrg.GetBitmap(&BmpInfo);
CDC *pDC=GetDC();
CDC MemDC,MemDC2;
if (MemDC.CreateCompatibleDC(pDC) && MemDC2.CreateCompatibleDC(pDC))
{
CBitmap Bitmap;
CSize szThumbnail(32,32);
if (Bitmap.CreateCompatibleBitmap(pDC,szThumbnail.cx,szThumbnail.cy))
{
CBitmap* pbmpOld=MemDC.SelectObject(&Bitmap);
CBitmap* pbmpOld2=pDC->SelectObject(&BitmapActual);
MemDC.StretchBlt(0,0,szThumbnail.cx,szThumbnail.cy,0,0,BmpInfo.bmWidth,BmpInfo.bmHeight,SRCCOPY); //this function will create a thumbnail
MemDC.SelectObject(pbmpOld);
MemDC2.SelectObject(pbmpOld2);
}
MemDC.DeleteDC();
MemDC2.DeleteDC();
}
ReleaseDC(pDC);
|
|
|
|
|
I think if you use StretchBlt for change size not good
see (of course its a suggestion)
<br />
CRect rect;<br />
Image *img ;<br />
ImageAttributes imAttrib; <br />
<br />
Graphics graphics(GetDC()->m_hDC) ;<br />
GetWindowRect(rect);<br />
ScreenToClient(rect);<br />
img = Image::FromFile(L"D:\\0.bmp") ;<br />
graphics.DrawImage(img,Rect(0,0,rect.right/2,rect.bottom/2),<br />
0,0,img ->GetWidth(),img ->GetHeight(),<br />
UnitPixel,&imAttrib);<br />
whitesky
|
|
|
|
|
Hi,
I Have used
MessageBox(NULL,"Please wait","Information",MB_OK).
to display message box in win32 DLL.
But now i need display a Message Box without any button ,i.e This message box should disappear itself after few seconds ...
Manjunath S
GESL
Bangalore
|
|
|
|
|
;Pcreate a dialog, and use time event......
|
|
|
|
|
Make a dialog box as you want. Now create this dialog using DoModal() in a thread function. Just initiate that thread when you want to show that dialog and kill the thread when you want to make the dialog disappeared.
Good luck
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|
|
for this purpose i think you need to create your dialog instead messagebox
whitesky
|
|
|
|
|
See here.
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Dear all,
I am doing a list box project but it need to show non-english word such as Japanese and German. How can the list box support on it???? Because it show "$de2&" now... THx a lot
|
|
|
|
|
Unicode .... :->
Maxwell Chen
|
|
|
|
|
Add unicode support for your application
|
|
|
|
|
|
my word is unicode already.....I don't know why it can't display in the list box????
|
|
|
|
|
How you use them?
whitesky
|
|
|
|
|
hi
i want to know that how spin control can be attached to its buddy that is some edit control
and i want to know that CWnd *pParent is used in dialpog based. if we use pParent in pWndbuddy in followng statement:
m_spin.SetBuddy(CWnd *pWndbuddy)
then it gives error so tellme wat can i use here.
Ashish Dogra
MCA
Noida
|
|
|
|
|
You can set the buddy for the spin control as
//m_spinCtrl is variable for the spin control and m_editctrl for edit box
m_spinCtrl .SetBuddy (m_editctrl.GetWindow(IDC_EDIT1));
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
sir thanks for reply
but it does not work as i use this in oninitdialog function
m_spin.SetBuddy(m_edit.GetWindow(IDC_EDIT2));
whwre m_spin is variable of spin control
and m_edit is variable of edit control.
Ashish Dogra
MCA
Noida
|
|
|
|