|
Hi,
When I compile and ActiveX object using ATL, I can see the "Performing Registration" friendly message in the Build View.
My question is.. what operations does it performs ? Only RegSvr32 ? or RegTLib or... ?
Thanks, Bye !
Braulio
|
|
|
|
|
Hola Braulio!
Go to Project -> Settings -> Custom build tag. The commands executed after building the object are:
regsvr32 /s /c "$(TargetPath)"
echo regsvr32 exec. time > "$(OutDir)\regsvr32.trg" which executes rgsvr32.exe and times the operation. It could be that the commands are different for the particular project configuration you selected, but now you know where to look
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Hola Joaquin !
I looked at that, I was very confused because, I can make work my ActiveX COM Object if I compile the source code in the same machine ( if not then it will fail to pass the metafile for the thing of handling my activeX inside a word automated instance in my MFC app), I thought maybe I forget to register the TLB or ... no idea
I don´t know what to do..., The only ideas that I have is to Marshal the interface ( now what I make is to have an Stream in HGlobal that should be enough), or try to get the metafile buffer and paste it in an safe array or as CData in an XML Dom tree).
What do you think ?
Braulio
|
|
|
|
|
Ummm... If you go to Project -> Settings, select your .idl and then the Custom Build tag, you can see the command midl is invoked.
midl /Oicf /h "test.h" /iid "test_i.c" "test.idl" I hope this makes some sense to you (I'm no expert in ATL COM stuff).
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Many of us work for Corporations that have central servers. This NT\2K servers each have a list of available users that are allowed to connect to the server. Is there anyway to Query the server and get the entire list of users? Also, Is there any way to query each network computer and see what user is logged on?
Nothing is impossible, It's merely a question of figuring out HOW?
|
|
|
|
|
NET_API_STATUS NetUserEnum(
LPCWSTR servername,
DWORD level,
DWORD filter,
LPBYTE *bufptr,
DWORD prefmaxlen,
LPDWORD entriesread,
LPDWORD totalentries,
LPDWORD resume_handle
);
NET_API_STATUS NetWkstaUserEnum(
LPWSTR servername,
DWORD level,
LPBYTE *bufptr,
DWORD prefmaxlen,
LPDWORD entriesread,
LPDWORD totalentries,
LPDWORD resumehandle
);
check http://www.mvps.org/win32/
|
|
|
|
|
Thank you much!!! That's just what I was looking for...
Nothing is impossible, It's merely a question of figuring out HOW?
|
|
|
|
|
i have something wrong but not sure what to look for.
the directory that i am passing is vaild (i can use _rmdir() and it works using the same variable.
but my problem is that i do not know how may files or sub-diretories may be in the the folder that i wish to delete. From what i understand this function will delete folders that have contents. i have been trying to delete for now an empty folder dirname = c:\\junk
when i run SHFileOperation() i get:
Cannot Delete File: File System Error(1026)
if i check the attributes on the directory there is nothing checked.
thank you for any help
SHFILEOPSTRUCT shf;
memset(&shf,0,sizeof(shf));
shf.hwnd = mywindow::GetSafeHwnd();
shf.wFunc = FO_DELETE;
shf.pFrom = dirname;///////////////this is a valid directory
shf.fFlags = FOF_SIMPLEPROGRESS | FOF_NOCONFIRMATION ;
int shfret = SHFileOperation(&shf);
|
|
|
|
|
The pFrom member is a "multistring", i.e a string composed of many substrings terminated by '\0' s. In your particular case, there's only one substring terminated by '\0' plus the standard '\0' regular C strings are equipped with. So, try with "c:\\junk\0" and tell us if that worked.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Can anyone help me?
If I override window sizing (lock WM_NCLBUTTONDOWN / HTLEFT..HTBOTTOMRIGHT and so on until WM_LBUTTONUP), do i have to dispatch WM_ENTERSIZEMOVEs and WM_EXITSIZEMOVEs? Where do they appear - in DefWndProc main message loop or sent by WM_NCHITTEST / sizing handler?
|
|
|
|
|
Cryst wrote:
WM_ENTERSIZEMOVEs and WM_EXITSIZEMOVEs? Where do they appear
These messages are sent in the DefProc handler for WM_SYSCOMMAND with the SC_SIZE, or SC_MOVE flag set in this message.
I am not quite sure what your question is, or what you are trying to accomplish, however, here is the flow of message generation. If the message is indented, that means that it is generated in the DefProc handler for the message before it.
WM_NCHITTEST
WM_SETCURSOR
WM_NCLBUTTONDOWN
WM_SYSCOMMAND
WM_GETMINMAXINFO
WM_ENTERSIZEMOVE
WM_SIZING / WM_MOVING
WM_CAPTURECHANGED
WM_WINDOWPOSCHANGED
WM_NCCALCSIZE
WM_NCPAINT
WM_WINDOWPOSCHANGED
WM_SIZE / WM_MOVE
WM_EXITSIZEMOVE
I hope this helps you.
|
|
|
|
|
Thank you!
I hope you could help me.
-----Method != Objective,COM != Panda-----
|
|
|
|
|
How can I add an option to the Shutdown menu in the Windows 9x? (Or, should I say, can I add an option?)
icounter
|
|
|
|
|
There is an article about manipulating the start-up menu. I dunno if you can add anything to the shutdown dialog, I don't see why not...?
However you could I imagine display your options prior to the shutdown dialog using this authors techniques.
Start Menu
Cheers!
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
I asked this questio earlier and didn't get an answer...perhaps I was to vague i'll try and be more specific.
I have derived a class from CControlBar(which is derived from CWnd so nothing should change much should it...?)
and naturally overriden the Create().
My window(derived CControlBar) is created but also creates it seems 2-3 others???
I used spy to verify the window was created and it's show a few more childs then I thought should be there...?
ANyways...using Spy I determined that the reason my CControlBar isn't showing is because it has a negative height.
0,0,320,-2...???
What do I have to do to show the Window...? i've done this a hundred times with generic CWnd, but the same doesn't apply to the CControlBar obviously.
When createing the CControlBar I specify a command ID within range:
AFX_IDW_CONTROLBAR_FIRST+32
What else am I missing...?
Thanx!
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
Did you call CFrameWnd::DockControlBar or CFrameWnd::ShowControlBar?
Tomasz Sowinski -- http://www.shooltz.com ** If you're going to rape, pillage and burn, be sure to do things in that order. **
|
|
|
|
|
Here is the following code from CMainfFrame::OnCreate()
m_wndTool.Create(this, WS_CHILD |WS_VISIBLE, AFX_IDW_CONTROLBAR_FIRST+35);
m_wndTool.SetBarStyle(CBRS_ALIGN_TOP | CBRS_GRIPPER);
m_wndTool.EnableDocking(CBRS_ALIGN_ANY);
EnableDocking(CBRS_ALIGN_ANY);
DockControlBar(&m_wndTool, AFX_IDW_DOCKBAR_TOP);
I can't figure out what i could possibly be missing...
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
HockeyDude wrote:
I can't figure out what i could possibly be missing...
CFrameWnd::ShowControlBar?
Tomasz Sowinski -- http://www.shooltz.com ** If you're going to rape, pillage and burn, be sure to do things in that order. **
|
|
|
|
|
Sorry
I didn't even notice that...I basically created a q and d app and modified a CDialogBar/CToolBar, neither had ShowToolBar and they worked so I never even noticed.
Thanx though...i'll try it out and hope it works, cuz this is driving me crazy...
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
I was afraid I would have to say this.
ShowControlBar didn't do it neither.
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
Hmmm... I'm not sure which virtual methods you have to override when deriving from CControlBar. Did you play with CalcXXXLayout?
Tomasz Sowinski -- http://www.shooltz.com ** If you're going to rape, pillage and burn, be sure to do things in that order. **
|
|
|
|
|
Yup i've tried all of that.
I took a CDialogBar and stripped it down to nothing, but the bare essentials....but when I remove the resource everything goes bad.
I'm going to pick apart the CControlBar today and hope I figure something out.
I don't understand why it's so different...it doesn't look like it adds that much functionality to CWnd...?
Thanx!
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
Hi,
I like to port my current WTL apps to Visual Studio .NET but I've tried to build a standard WTL app first. I've included the paths to WTL and using WTL 3.1. The following warnings and errors occur:
Compiler warnings:
atlapp.h line 400: conversion from 'LONG_PTR' to 'LONG', possible loss of data
atlapp.h line 433: conversion from 'LONG' to 'WTL::CAppModule *' of greater size.
Runtime error:
Assertion: Allocate.cpp, line 247: (iCategory < m_pProcess->CategoryCount()) || (iCategory == -1)
Can anyone tell me if it is just a compiler setting or is there an update of WTL for Visual Studio .NET?
Thanks in advance,
Remon
|
|
|
|
|
You need to #define a symbol before #include'ing the WTL headers. It's one of those ".._TMP_IMPL" symbols, but I forget the exact name. It was mentioned on one of the front-page articles some months ago.
--Mike--
It's hammer time!
My really out-of-date homepage
Sonork - 100.10414 AcidHelm
Big fan of Alyson Hannigan and Jamie Salé.
|
|
|
|
|
Can you give me a direction where to search?
Thank you
Remon
|
|
|
|