|
Have you taken a look at D3DSpy, which ships with the DirectX 9 SDK? It may provide the information you're looking for.
- Mike
|
|
|
|
|
Dear Techies,
Please give me the differences between the member functions prefixed with Afx and without Afx.
For Example, AfxMessageBox() and MessageBox();
What's the additional features and capapbilities does the AfxMessageBox() has over MessageBox().
Thanking you,
Neelesh K J Jain.
|
|
|
|
|
one is api, and the other is mfc.
one is global, and the other is local.
little suggestions.
Hello World!
|
|
|
|
|
I want a book that's as thorough as Prosise's Programming Windows with MFC, only that it's MFC centric in the latest (7.0 or 7.1) versions of MFC. Is there such an animal? A search of the internet yields nada. There is a gaping hole here that needs to be filled. What's the hold up?
Ed
|
|
|
|
|
I need to write a small program that will run in the background and trap whatever is typed at the keyboard with whatever program that's running. Then save those keystrokes to a file. Is there an easy way to do this?
Thanks,
Fred
It's all magic.
|
|
|
|
|
Yes, but it's a rude thing to do.
--
-Blake (com/bcdev/blake)
|
|
|
|
|
Hm... may I ask you why you want to do this?
Rickard Andersson
Here is my card, contact me later!
UIN: 50302279
Sonork: 37318
Interests: C++, ADO, SQL, Winsock, 0s and 1s
|
|
|
|
|
Rickard Andersson18 wrote:
Hm... may I ask you why you want to do this?
hmm... maybe he wants to create a keylogger so that he can install it onto everyone's pc and get all their passwords?! ;)
"It was when I found out I could make mistakes that I knew I was on to something."
-Ornette Coleman
|
|
|
|
|
Sure true, then I won't help.
Rickard Andersson
Here is my card, contact me later!
UIN: 50302279
Sonork: 37318
Interests: C++, ADO, SQL, Winsock, 0s and 1s
|
|
|
|
|
The part under the (if aorh == 0) works great . The part in the else{} brackets dosn't and causes a fatal error in my program when I run it as well as a WSAEPROTONOSUPPORT error I don't understand. I must be doing something screwy.
void CSSPingDlg::Ping(LPCSTR pstrHost, int aorh)
{
SOCKET rawSocket;
LPHOSTENT lpHost;
rawSocket = socket(AF_INET, SOCK_RAW, IPPROTO_ICMP);
if (rawSocket == SOCKET_ERROR)
{
AfxMessageBox("Raw socket initialization failed.",MB_OK);
return;
}
if (aorh == 0)
{
lpHost = gethostbyname(pstrHost);
saDest.sin_addr.s_addr = *((u_long FAR *) (lpHost->h_addr));
saDest.sin_family = AF_INET;
saDest.sin_port = 0;
}
else
{
lpHost = gethostbyaddr(pstrHost,4,AF_INET);
saDest.sin_addr.s_addr = *((u_long FAR *) (lpHost->h_addr));
saDest.sin_family = AF_INET;
saDest.sin_port = 0;
}
|
|
|
|
|
the 'aorh' is your flag to go with gethostbyaddr but it doesn´t work. So you should check if your are allowed to use gethostbyaddr in this context/parameters. The error is poiting that you haven´t started the WSA properly to do this.
Try this @ home. (B&B)
|
|
|
|
|
KarstenK wrote:
The error is poiting that you haven´t started the WSA properly to do this.
Which is what WSANOTINITIALISED is used for.
Five birds are sitting on a fence.
Three of them decide to fly off.
How many are left?
|
|
|
|
|
It also can be that the startup wasn´t with the correct version, because on the other "if" side it worked.
Try this @ home. (B&B)
|
|
|
|
|
This should work just fine:
ULONG ulAddr = inet_addr("192.168.200.100");
if (INADDR_NONE != ulAddr)
{
LPHOSTENT hostinfo = gethostbyaddr((char *) &ulAddr, sizeof(ulAddr), AF_INET);
if (NULL != hostinfo)
{
....
}
}
I'm not sure what your code is doing after assigning values to the saDest structure, but have you ruled out that as a potential problem? In other words, do you really want port 0, or should you be using a port in the range 1024–49151? You can also use 49152–65535, but no services are registered on them, which you may not even care about.
What is lpHost->h_addr ? Shouldn't that be lpHost->h_addr_list ?
Five birds are sitting on a fence.
Three of them decide to fly off.
How many are left?
|
|
|
|
|
Several hours overtime at work and I am rewarded
with this little gem from VS 6.0
<br />
Compiling...<br />
StdAfx.cpp<br />
Compiling...<br />
TestMatrixTemplate.cpp<br />
c:\documents and settings\windows user\my documents\john's work folder\testmatrixtemplate\generalmatrixclass.h(60) : fatal error C1001: INTERNAL COMPILER ERROR<br />
(compiler file 'msc1.cpp', line 1786) <br />
Please choose the Technical Support command on the Visual C++ <br />
Help menu, or open the Technical Support help file for more information<br />
Command line warning D4028 : minimal rebuild failure, reverting to normal build<br />
Error executing cl.exe.<br />
<br />
TestMatrixTemplate.exe - 1 error(s), 1 warning(s)<br />
Can anyone provide any insight as to what the problem
REALLY is? The generalmatrixclass.h file is a
template for a proprietary matrix class. Could there be
something wrong with the implementation in the .h that
would cause this?
John Theal
Physicist/Mathematical Programmer
Digital Immersion Software Corporation
Got CAD?
http://www.presenter3d.com[^]
http://www.merlin3d.com[^]
|
|
|
|
|
I've got this a number of times when trying to use template functionality that isn't supported in VC6.0. In particular, whenever i've used a member function template, if i implemented it outside of the class definition (in a .inl file for eg) i would always get this problem - that one was resolved by moving the implementation into class itself.
If you post the code, i might be able to help further, otherwise i would suggest selectively commenting stuff out until it compiles
Dave
http://www.cloudsofheaven.org
|
|
|
|
|
You qualified most of your methods using CMatrix:: even though they are defined within the class definition. This is illegal (although VC should give a real error message). If you remove all of these it works - well, it shows you the real compile errors of which there are a couple, but those are easy to fix as it actually tells you what is wrong.
Dave
http://www.cloudsofheaven.org
|
|
|
|
|
Oh my I'm tired. Thanks for pointing that out.
Argh. I think I should take a break and go home
now. You know you've had enough when silly mistakes
like that start going unnoticed.
Thank you.
John Theal
Physicist/Mathematical Programmer
Digital Immersion Software Corporation
Got CAD?
http://www.presenter3d.com[^]
http://www.merlin3d.com[^]
|
|
|
|
|
for files that are self contained, you might try downloading gcc and giveing them a run through that. GCC tends to be slighty (to alot) more informative about whats wrong, particularly with template stuff. I have found a number of things that VC6 just completely lets slide through that are actually incorrect/invalid C++.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
|
|
|
|
|
This is for any Microsoft employees lurking around:
While prototyping our application, I have become very annoyed that MFC does not support the XP look and feel. Specifically, it uses the old style menus.
We have looked at some well known third party UI libraries and haven't been pleased with them; not only are they bloated, but they offer far more functionality than we need and don't quite give us the exact look and feel we want. (And the documentation for all of them sucks big time.)
The real irony is that WTL offers the look and feel we want, but since it's not officially supported, we are very unlikely to get a green light to use it. Besides, the documentation for it is a pitiful fraction of that for MFC.
Frankly, I don't care if Microsoft throws its weight behind WTL and updates and documents it (it's missing some common classes for app development) or if it updates MFC. But I wish they would make up their minds and do something other than let both wither and die.
Joe Woodbury
When all else fails, there's always delusion.
- Conan O'Brien
|
|
|
|
|
Joe,
Just curious ( I don't have XP so I am not familiar with the new mens) what do you have to do to support them? I am asking so that I know what to be aware of for the VCF. What features would you expect to find?
What do you mena by the "exact look and feel" surely if tehy are following the SDK API's they'll look right, correct? That's certainly the case with previous versions of Windows.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
|
|
|
|
|
Basically, the new design is like IE--the menu is a toolbar with flat buttons. I found some code on CodeGuru that mostly works, but it's a real pain and should be supported by MFC, IMHO. Actually, the real problem is that the color of the old style menus look out of place with a new style button bar. (This is arguably a problem with XP itself, but can't do much about that.)
"Exact look and feel" are the small things like whether to allow a docking menu or customizeable toolbar.
This has been an issue with all versions of windows, but has gotten worse in recent years due to the legacy support of all the old versions. Even with Office, Microsoft changes UI elements with every release.
Joe Woodbury
When all else fails, there's always delusion.
- Conan O'Brien
|
|
|
|
|
the menu is a toolbar with flat buttons
This is applied across the board for all apps? Ick, what a pain.
"Exact look and feel" are the small things like whether to allow a docking menu or customizeable toolbar.
So all menus can now be tear offs like Visual Studio or Office?
Even with Office, Microsoft changes UI elements with every release.
Right, but at least with Office it was localized to a singele app (or set of apps), and it was clearly a completely custom effort.
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
|
|
|
|
|
This is applied across the board for all apps? Ick, what a pain.
Well, no, that's the problem.
So all menus can now be tear offs like Visual Studio or Office?
If they are toolbars and you've done a few other things, yes. But that's the point--we don't want menus to be tear offs--it messes me up when it happens, imagine what it will do to our mass-market grandmotherly types! However, we do want the menus to match the look of the button bar.
and it was clearly a completely custom effort.
Well, yes and no. If the look catches on, it usually works its way into comctl32.dll and shows up in IE. The look of the gripper, for example, is constantly changing--now it's a vertical line of dots.
MFC has also been modified in the past to have the look and feel of Office apps. But then that stopped, largely with the .NET push.
Joe Woodbury
When all else fails, there's always delusion.
- Conan O'Brien
|
|
|
|
|
The offical line from MS is that there won't be any new enhancements in MFC, only bug fixes.
The want you to use .NET.
|
|
|
|