|
It is very difficult to answer that question if you can not remember the error message. But I think you should check again the following:
1. ALT.DLL is require if you build at MinSize mode. In this case, you can switch to MinDependency mode, so that ATL.DLL is independent.
2. If your DLL used MFC, you must ensure that in the computer where you get problem has installed MFCxx.DLL correctly. Ofcouse, in case DLL build with DEBUG mode, the MFCxx.DLL can be different.
Hope useful.
|
|
|
|
|
When adding new text at the botton how can you arrange for the scroll bar (vertical) to be set such that the last section of text is always displayed.
Currently when I move the scroll bar, it is reset when the program addeds the next bit of data.
|
|
|
|
|
After laying out multiple CToolbars in a CMDIFrame I have the following layout;
(1) Top of client area, 1st row, contains 5 toolbars (side by side)
(2) Underneath the above I have a 2nd row with two toolbars (side by side)
(3) At the bottom of the client area I have two more toolbars on a single row (side by side)
Unfortunately, when the user resizes the parent frame so that a toolbar to the right edge of window falls outside it, MFC decides to move the toolbar in question down one row. Even worse, it does not move it back afterwards!
This looks awful, and is very annoying.
Anyone have any suggestions on how to prevent MFC doing this?
I'm using the Visual C++ 6.0 IDE and that is able to keep its individual toolbars on the same row when I resize the main window (even when the toolbars go off screen) so how does it do it?
Many thanks,
Glidz
|
|
|
|
|
I am wondering how can I copy/backup a locked file.
Seems that almost all backup programs can do it so it's sound simple, but I can not find anything on this
Can you help me and give me some guide lines ?
what and where to search for ?
Thank you in advanced .
Vini
|
|
|
|
|
CoolVini wrote:
Seems that almost all backup programs can do it...
All the ones I've ever used will skip files open by other processes.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
If the process opening the file did not specify any sharing options, you cannot access it.
You should specify GENERIC_READ and FILE_SHARE_READ | FILE_SHARE_WRITE when openign the file.
Flirt harder, I'm a Coder
mlog || Agile Programming | doxygen
|
|
|
|
|
Anyone here knows how to do a program to calculate loan using MFC?I need some help.thanks
felix joe
|
|
|
|
|
What part of the computation do you want to know about? Do you have some code that is not working correctly? Is it too much to ask your instructor for some detailed instructions? Some will give you a few extra morsals that were not previously given in class (assuming you've at least bothered), while others will tell you to find the missing pieces on your own. Conspiring with classmates is also an option.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
I was wondering where i can get some info on the protocalls used by bank and stock servers. I need to make ann app which can buy and sell stock while managing money in specific bank acounts.
|
|
|
|
|
Help people!
I have just upgraded (still not really sure if it is an upgrade) to Visual Studio .NET
Using Visual C++ I have a library that needs to be linked to my app from the directory it was built in dependant on whether I am compiling for the debug or release version. So I have added the path to Tool/Options/VC++Directories/Library Files with the $(ConfigurationName) macro on the end. But it seems to make no difference, I can only get it to work if I put in the complete path.
Is this the correct macro? Or any tips?
Regards,
Kevin.
|
|
|
|
|
Add the appropriate directory to each configuration using the project property pages.
Using the project properties dialog box, navigate to linker->general->additional library directories. Add the directory for the appropriate folder, then change the configuration and add the other folder.
The ($ConfigurationName) macro may even be usable for 'all configurations'
If you can keep you head when all about you
Are losing theirs and blaming it on you;
If you can dream - and not make dreams your master;
If you can think - and not make thoughts you aim;
Yours is the Earth and everything that's in it.
Rudyard Kipling
|
|
|
|
|
I'm developping an ISAPI FILTER and I would like to know why this code for the event OnAuthComplete is not working; I have already declared the method and caught the notification (SF_NOTIFY_AUTH_COMPLETE: dwRet = OnAuthComplete(pfc, (PHTTP_FILTER_AUTH_COMPLETE_INFO))pvNotification); :
static DWORD OnAuthComplete(PHTTP_FILTER_CONTEXT pfc, PHTTP_FILTER_AUTH_COMPLETE_INFO pAuthCompInfo)
{
HANDLE TokenHandle = (HANDLE)1;
DWORD dwLen = 0;
PTOKEN_USER pTokenUser = NULL;
DWORD dwErr;
char name[MAX_NAME], domain[MAX_NAME];
// Get user token.
if ( pAuthCompInfo->GetUserToken(pfc,&TokenHandle) )
{
// Get token information size.
if ( !GetTokenInformation
(TokenHandle,TokenUser,NULL,dwLen,&dwLen) )
{
dwErr = GetLastError();
if ( ERROR_INSUFFICIENT_BUFFER == dwErr )
{
// Alocate buffer for token information.
pTokenUser = (PTOKEN_USER)GlobalAlloc(GPTR,dwLen);
dwErr = S_OK;
}
}
// Now get the actual token information.
if ( dwErr != S_OK ||
!GetTokenInformation(TokenHandle, TokenUser,pTokenUser,dwLen,&dwLen) )
{
// Error …
}
else // We have the token information in hand.
{
// Extract from the token information - the SID.
SID *pSid = (SID *)pTokenUser->User.Sid;
DWORD dwNLen = MAX_NAME, dwDLen = MAX_NAME;
SID_NAME_USE eUse;
// Get the user name and the domain from the SID.
if (!LookupAccountSid(NULL,pSid,name,&dwNLen,domain,&dwDLen,&eUse) )
{
// Error …
}
else
{
// name buffer contains user name.
// domain buffer contains user domain.
}
}
}
if (*name != NULL)
return WriteIntoFile(pfc, "OnAuthComplete: User name:" + *name);
else
return WriteIntoFile(pfc, "Evento OnAuthComplete: ");
}
WriteIntoFile is a method that write into a file and I have already tested it and it works well.
|
|
|
|
|
How can write a cookie from vc++ without ATL or MFC?
|
|
|
|
|
See this thread.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Yes, but I must use the ATL COM!
And without ATL? An application .exe that write a cookie.
No asp, php, cgi, perl....
|
|
|
|
|
black976 wrote:
...without ATL...
Yes, but I must use the ATL COM!
These two statements contradict each other.
Did you even look at the code in the MSDN article Q241492, specifically step 6? That's C++ code that can be used with or without ATL.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Excuse me. I don't understand...
http://support.microsoft.com/default.aspx?scid=kb;EN-US;240191
this article shows "HOWTO: Read Cookies Using ASP and Visual C++" Ok?
To create a indipendent .exe without dll?
Thank you very much.
|
|
|
|
|
Create a new EXE using the code in step 6. But if you aren't going to be using the code on an IIS machine, it's pretty pointless.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
When I write a net program, I use CSocket class to communicate with the serve. but after connected, i can't find a way to identify whether the server is still connecting. who can help me, please.
|
|
|
|
|
when you recv() from your socket, 0 is the return value for "the other part closed the connexion"
TOXCCT >>> GEII power
|
|
|
|
|
I have converted an old Visual C++ 6.0 into a Visual Net project.
After some reprogramming the program works fine when it is
beeing started from inside .NET (Ctrl + F5)
However when I try to start it using the exe file created by
.NET it will not start. The exe tries to start and uses almost
100% of the available CPU power, but then it only hangs and
the GUI never appears.
I tried to start the exe files on several different computers
and the same error occurs on all of them.
Anyone who have had this problem and know how to solve it?
/Abram
|
|
|
|
|
Hi everybody,
i need to import a library file(winmm.lib) into my project using VC++.NET. The way to do that is so different from VC++ 6.0. Does anyone know how to do?
Thanks in advance.
|
|
|
|
|
how about
#pragma comment(lib, "winmm.lib") ?
that should work on both 6.0 and .NET
We are men. We are different. We have only one word for soap. We do not own candles. We have never seen anything of any value in a craft shop. We do not own magazines full of photographs of celebrities with their clothes on. - Steve
|
|
|
|
|
Thanks for your reply, Hendrik, but it didnt work.
In VC6.0, i can import it in ProjectSetting\Link Tab, but in .NET - hix, cannot
|
|
|
|
|
you need to announce the whole path to your library file inside the pragma comment instruction ...
#pragma comment(lib, "path_to_lib/libname.lib")
We are men. We are different. We have only one word for soap. We do not own candles. We have never seen anything of any value in a craft shop. We do not own magazines full of photographs of celebrities with their clothes on. - Steve
|
|
|
|