|
Try calling WaitForSingleObject with the VC's process handle
Concussus surgo.
When struck I rise.
|
|
|
|
|
It must use hook?who can introduce the easy way?
Hi
|
|
|
|
|
I'm thinking you could:
Use FindWindow() to find the parent window in which you listview/ctrl resides. Iterate the the child windows using GetWindow() and stop when you find the window whose class is "SysListView32" or "msctrls32" or whatever...actually use SPY++ first to determine the class name, cuz i'm unsure...
Once you have the handle to that listview window attach it to an CListCtrl object and goe nutts...extracting items just like you normally would...
cheers
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
I have tried it.But it don't work.I think it maybe use pointers and other application can't access your pointer.
Hi
|
|
|
|
|
|
Thanks!It works.
Can't I ask you another question?
I also want to get the item RECT.I use ListView_GetItemRect() in the
same way,but when run it report memory violation.I think it maybe
use other parameter.How can I do it?
Thanks again!
Hi
|
|
|
|
|
Is it possible to send WM_KEYDOWN message to a window that is currently minimized, and the window reacts just as if the user presses the key on it?
|
|
|
|
|
I don't know if windows filter out messages when minimized, but I think what you are trying to accomplish is possible...of course if you tried it you'd know for sure...
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
hi, i tries to load a .x file but keep failing... i got this code fragment from a text...
code as follows:
HRESULT result = m_pD3D->CreateMeshBuilder(&m_pMeshBuilder);
if(result != D3DDRM_OK)
return FALSE;
result = m_pMeshBuilder->Load("model.x", NULL, D3DRMLOAD_FROMFILE, NULL, NULL);
if( result != D3DRM_OK)
{
MessageBox("Load error");
}
QUESTION 1: I realise HRESULT is a COM structure. How can i get more specific hint from result?
QUESTION 2: is there any specification to how 3ds files are converted into .x files using conv3ds.exe? the original model.x that comes with the book works just fine. But when i use other .x files i got from other sources, result != D3DRM_OK... and i cant figure out why?
QUESTION 3: I cant find documentation for ???::Load method
QUESTION 4: LPDIRECT3DRMMESHBUILDER structure documentation?
Thanx
|
|
|
|
|
if the conv3ds.exe you're using does not come with the SDK version you're using I don't recommend you use as it might be an older format. IIRC the DirectX SDK comes with a MAX plugin. Look for it. It should be under the tools folder.
Do you have the Debug version installed and selected?
If you do, what does the debug spew say?
Always, always use the Debug version and look at what it says. It catches alot of useful stuff (redundant state changes for example). Also, if you have any rendering probs use REFRAST as it will allow you to separate bugs in your code from bugs in the drivers. If the problem persists when using REFRAST then the problem is in your code.
HTH
Brian Azzopardi
bibamus, edamus, cras moriemur [eat, drink, for tomorrow we die]
|
|
|
|
|
norm wrote:
QUESTION 1: I realise HRESULT is a COM structure. How can i get more specific hint from result?
Add a watch with "result,hr" to see the message. (without quotes)
Concussus surgo.
When struck I rise.
|
|
|
|
|
Hi!
I'm building an MFC application and I'm trying
to link a home made .lib to it. The library
uses the STL. When I try to compile the MFC
app, I get messages like these:
error LNK2005: "public: __thiscall std::basic_string<*snip*> already defined in MainFrm.obj
and
MSVCRT.lib(MSVCRT.dll) : error LNK2005: _memmove already defined in libcmt.lib(memmove.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: _vsprintf already defined in libcmt.lib(vsprintf.obj)
MSVCRT.lib(MSVCRT.dll) : error LNK2005: _fclose already defined in libcmt.lib(fclose.obj)
I can work around it, but I don't know what the
root problem is. I think it's releated to which
run time library the app uses. Any ideas?
Shawn
|
|
|
|
|
Try changing the C Runtime libs of your application to match your lib. This way, CRT symbols won't get duplicated.
Concussus surgo.
When struck I rise.
|
|
|
|
|
Most of this has nothing to do with the STL, but rather the C runtime library.
Christian
We're just observing the seasonal migration from VB to VC. Most of these birds will be killed by predators or will die of hunger. Only the best will survive - Tomasz Sowinski 29-07-2002 ( on the number of newbie posters in the VC forum )
Cats, and most other animals apart from mad cows can write fully functional vb code. - Simon Walton - 6-Aug-2002
|
|
|
|
|
Looks like that works. Thanks
Shawn
|
|
|
|
|
I have a list view and i want it so that when the user clicks on an item in the list, the box that surounds the selected item and greys it out a little does not appear. How can I accomplish this?
There's always one more bug.
|
|
|
|
|
Two ways AFAICS:
1) Override OnLButtonDown() in a derived class and have it save the current selection index (incase you need that item later) then SetCurSel(-1) to prevent any further selection.
2) Ownerdrawn or custom drawn your choice
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
Hi Everyone,
I have been stuck with this questions for two days, could anybody help me
out?
I want to add customized counters to Performance Monitor(PerfMon.exe) in
Win2000, so that in Performance Monitor I can monitor some data defined by
myself in my application. I have referenced two articles "Instrumenting
Windows NT Applications with Performance Monitor"
(http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnperfmo/h
tml/msdn_ntperf.asp) and "Enable your VB components to talk with the Windows
Performance Monitor"
(http://www.devx.com/premier/mgznarch/vbpj/1999/05may99/kk0599.pdf)
But these two samples all don't work correctly on my Windows2000, that is in
Performance Monitor I still can't see the performance object I want to add.
I have checked the Registry, everything seems fine.
Since these two articles all talk about WindowNT, I am wondering if this is
the problem because I am working on Win2000. What should I do in Win2000?
Has anyone ever written this kind of application, can you give me a hint on
how to make your application expose counters that can be analyzed in
Performance Monitor?
Thanks!
Sherry He
|
|
|
|
|
Hello,
As a matter of fact, I have written this type of application for a company I used to work at.
It's about 5MB, so if you tell me a way to send it to you, I will.
Chris
chris@outreach4him.50megs.com
|
|
|
|
|
Hi,
My app is performance critic and so I wanted to set the optimisations (VC 7.0) in the release verison of my app. Now when I fire up the application I give the user a startup configuration dialog. Before the optimisations it drew the background default grey as I wanted it to. Now the dialog background is white, the control backgrounds are grey though. Anyone else came across this problem?
|
|
|
|
|
its release version i suppose, but did u ASSERT in it, cos if u did ASSERT is nasty!! If u did ill tell u why!
|
|
|
|
|
Is there any way to detect if the user has locked the workstation in WinNT/2k/XP?
Regards,
Venet.
Donec eris felix, multos numerabis amicos.
|
|
|
|
|
For W2K (only), you could look at :-
http://www.codeproject.com/useritems/winlogon_notification_package.asp
For NT, I havnt heard of this being successfully acheived without either :-
a) totally replacing the NT GINA, with one of your own,
b) (or) using a pass-thru GINA, which intercepts the items
you wish to trap, (actions them) and then calls the 'real' GINA.
Both NT methods appear complicated and dangerous !!! - If you wish to know more, Windows Developer Journal (WDJ) had a series of articles written by Pamela (something beginning with "T" [apologies to Pamela], who's an expert in this field, you could pick up the CD-ROM of back-issues if you were really serious about doing it)
Microsoft do supply a GINA example in the SAMPLES directory of the MSDK kits, as well (but the articles mentioned above are the way to go ...)
HTH
'G'
|
|
|
|
|
Thanks,
I think I must have a look at WDJ for those articles.
I did think that it might be just sending a WM_ message to the app, but then again, finding no info in MSDN made it doubtful.
Thanks for the info
Regards,
Venet.
Donec eris felix, multos numerabis amicos.
|
|
|
|
|
You get teh answer you were looking for??????
Regards,
Brian Dela
|
|
|
|