Answer Questions
Jan Kučera "Custom build step" of a project: execution rule ?
Hi, I am presently using "Visual Studio 2005". I defined a project to generate a DLL X but I needed to do other operations on this DLL X to generate a file Y. So I added a "Custom Build Step" on the project file to generate the Y file. I defined Y as the output file and I even added X as an additional dependency file. I changed the execution order of the Custom Build Step and put it before the "Post Build Event". The problem is that the generation of Y seems to be unpredictable. Sometimes the "Custom Build Step" doesn't run, even if Y is outdated compared to X. And sometimes the "Custom Build Step" always run, even if Y is newer that X... In both case the configuration seems the same. So I don't understand how it is supposed to work. I rea ...Show All
abcdefgqwerty2 mfc build problem in vs2005
I have been getting the following error messages whenever I try to build MFC programs, and on MFC programs that have previously built without error. I've tried compiling each file seperately, and, you guessed it, each one gives me these same error messages. I've tried rebuilding the MFC Include directory, reinstalling VS, and still continue to get these errors whenever I try to build or just compile. Again, they have previously build just fine. I've scoured the headers, and can find no issue. I've built, rebuilt, compiled, all to no avail. I'm currently using the trial edition of VS Pro that I installed on 8/1/2006 (though I fully plan to purchase the full version as soon as my financial situation allows). Is that an issue with this ...Show All
ignitionflip Populate Combo Box with physical Drives
Hello Everybody, I'm working on a windows forms project that includes a combo box which I need to populate with the list of physical drives present in the system at that point. The purpose is to allow the user to select a physical drive to run some tests. Any ideas Thanks!! Sure, unfortunately no idea why there is no example in VC++ http://msdn2.microsoft.com/en-us/library/system.io.driveinfo.getdrives.aspx ill move the thread to the appropriate forum now to the VC++ however I hope that the example I gave helps you in some way, at least logically the GetDrives() returns back an array of DriveInfo objects, then simply iterate through each DriveInfo object in the c ...Show All
Divermarv Please Help Me...
Hi everyone, My name is Krishna Prasad, i recently joined America Online(AOL-BDC) and currently working on VC++. Actually, am facing here a problem and badly need a soluiton for it... As, am a fresher i'm in a sort of confusion. I need to retrieve the path and names of the files that are zipped i .e : I need to retrieve the name of files and paths f all the files zipped in a single folder ... Please,help me in solving this problem. With Anticipation, Thanks, Krishna Prasad H I'm afraid this question isn't very well suited for this forum, as it deals with the C++ language, as implemented by MSVC 2005. I suggest you head over to the news groups, e.g. http://msdn.microsoft.com/newsgroups/default.aspx dg=microsoft.publ ...Show All
hrubesh assigning derived class from base class declaration
Hello; For the following code, know that Poodle is a derived class of Dog, and that aPoodle is an instanciation of Poodle. In the code below, I would expect dogObject to become a pointer to aPoodle, but it doesn't seem to work for me. Instead, dogObject seems to only maintain the attributes of dog. Any idea what I may be doing wrong ____________________________________________________________ Dog *getDogObject() { Dog *dogObject; DogTypes dogType; // an enum of dog types (poodles, hounds, etc..) dogType = getDogName(); switch (dogType) { case DogTypes::poodle: dogObject = &aPoodle; // <======= PROBLEM HERE break ; } dogObject->jump(); // <===== CALLS DOG.JUMP, NOT POODLE.J ...Show All
MDesigner kicking out the old, tripping over the new...
Hi! How do I take: sscanf_s(strOneLine, "%g %g\n" ,&Data.x,&Data.y); And write it in VC++ 2005 so I don't get: cannot convert parameter 1 from 'CString' to 'const char *' while having the exact same functionality Thanks, Swampie This compiles gracefully on my computer: CString strOneLine; float x, y; sscanf_s(strOneLine, "%g %g\n" ,&x,&y); Maybe you should try _stscanf_s instead of sscanf_f _stscanf_s (strOneLine, _T ("%g %g\n"), . . . ); I hope it works. ...Show All
shahafin Linker error porting an NT service from VC 6.0 to VC 8.0 - using a makefile
I am trying to port a service from VC 6.0 to VC 8.0. My VC 6.0 service was compiled from the commandline using a makefile. I created a Makefile project in VC 8.0. I did NOT create a Windows Service project in VC 8.0 because I am not using CLR. After resolving various compiler and linker issues, the last remaining issue is: error LNK2019: unresolved external symbol "int __stdcall AfxSocketInit(struct WSAData *)" ( AfxSocketInit@@YGHPAUWSAData@@@Z ) referenced in function "int __cdecl setup_server(void)" ( setup_server@@YAHXZ ) The list of libraries I'm linking includes: libcpmt.lib $(conlibsmt) $(olelibs) $(winsocklibs) version.lib user32.lib advapi32.lib mfc80.lib atl.lib atls.lib What library ...Show All
Eugene S.B. Getting bug report support from Microsoft
I have recently reported a private bug to Microsoft, a "C++ CodeDOM parser error: Internal Error", which blocks my efforts to continue component development for one of my components in C++/CLI. The bug was reported a week ago but has evidently not been reviewed by Microsoft. The bug is detailed at http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=671820&SiteID=1 on this site. Is there a way to contact Microsoft directly so that I can have this bug looked at and so that I can get a workaround or fix which enables me to successfully complete and market my component Also, does anyone know whether file attachments added to public bug reports are downloadable by all users or only by Microsoft I made my bug report private beca ...Show All
Grotius Trying to pass a Function Name as an Argument to a function
Greetings, Let's try this again and I will try and be a little more clear in my questions. I have created a class library, let's call it ClassA and in that class I have a function, lets call that FunctionA. FunctionA processes my data then calls another function, the name of which is passed as an argument to FunctionA, so I would declare my function as follows: int ClassA :: FunctionA((int) (PassedFunctionName)(void *, void *), int PassedInteger) During the process FunctionA call PassedFunctionName with 2 void pointers as arguments and expects an integer return. PassedFunctionName is determined by the calling program, not by the library (ClassA). Now my Program has a class, let's call it ClassB, which has functions called Fu ...Show All
Demix help needed for multithreaded animation in VC++ 6.0
Hello! I was trying to develop an animation in Visual C++ 6.0 on WinXP when i came across this problem: i was trying to run animation inside a thread: DWORD WINAPI AnimationThread(LPVOID param){ for(i=1;i<15;i++) { ................................. ................................. //AniProc1 and AniProc2 are functions to create animations SetTimer ((HWND)param, ID_FLASH,100, AniProc1); SleepEx(2000,1); SetTimer ((HWND)param, ID_MOVERIGHT,5, AniProc2); SleepEx(2000,1); ....................... ....................... .................. } All of a sudden the animation stops (during 12th loop ...my code contains no special condition related to the 12th loop in particular) Plz hel ...Show All
ELDHOSE_BABY_a06ce9 Make QuickWatch window resizable
Please, make the QuickWatch window resizable. With long variable names or values, it is impossible to read. A related improvement would be to set the column widths to match the column contents. This wouldn't solve the long width problem, but would help. Just go to the bottom right corner, there is a "gripper" you can use to resize it. I find it amusing that even the VC++ team didn't know how to do this. I'll bet it isn't documented, either. OK, then, how do you resize it Dragging on the edges doesn't do anything. Here is what I get, every time: Sign In to Microsof ...Show All
Matt354245 System.Timers.Timer not elapsing
I have a two timers in my service that will be reset after some work gets completed. The problem comes in if the service is left running for a few days, the timers will reset but then not elapse. The problem is that without the timers elapsing no work gets accomplished. Any ideas I don't think that's the problem since I'm only experiencing this in one environment but in all others I'm not. Is there something that will be able to determine what is causing the problem since nothing is written in the event log. Basically, I have a service that looks for work on a queue. The timer is started at startup, when the timer elapses the timer is disabled the queue is checked for w ...Show All
badrinarayanan installation
i'm trying to install VC++ express on my computer, without internet. I read the guid for this, but when I exracted all the .img files, and started the setup, & an error would occur. It would say insert the EMU disc (whatever that is), and wanted a certain file. Please Help! Normally we are using ISO images, which is virtually mounted to some drive in your machine. See the link below to know more about it and get the list of tools. http://en.wikipedia.org/wiki/ISO_image ...Show All
vr3h Disk Serial Number
I am looking for a way to get disk (hardware) serial number from the Visual C. I tried to call to DeviceIoControll with IOCTL_DISK_GET_DRIVE_LAYOUT In the DRIVE_LAYOUT_INFORMATION structure I use field Signature. Whether this value is unique Is it changed after format What is this field Not enough information about this field in MSDN. Thanks For such issues, please use the newsgroups at http://msdn.microsoft.com/newsgroups OTP Thanks, Ayman Shoukry VC++ Team ...Show All
Kaveh Shahbazian Mixed mode finalizer bug in C++ class destructor with std::vector member
I have discovered a bug when finalizing a CLR class which deletes a data member which is a pointer to a C++ class, and the C++ class has a std::vector<ANYTYPE> as a data member. When this occurs an exception is thrown, with the message in the debugger being: "An unhandled exception of type 'System.AccessViolationException' occurred in msvcm80d.dll Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt." Breaking in the debugger shows that the exception is occurring in the stack trace from the vector's destructor code, with the last source code trace being line 45 of xmtx.c in an _Mtxlock routine. Tracing the bug shows that the finalizer has executed afte ...Show All
