Answer Questions
S.Mark Creating a DLL
Hi, I currently have an application, which uses lame_enc.dll to encode audio into MP3 files. There is another encoder available as gogo.dll which uses ASM hand-optimised routines, and is therefore much faster. Without modifying my application, I want to create a new lame_enc.dll file which will simply pass data onto gogo.dll, and translate any settings required. Therefore giving the option to add a much faster encoding engine into my application. The manual for gogo.dll is here http://homepage1.nifty.com/herumi/soft/gogo2/man/ (no source code is provided) lame_enc.dll manual is available here: http://www.fi.muni.cz/~qruzicka/Smid/man.htm Source for lame_enc.dll is available from mp3dev.org. Hope someone can help me, ...Show All
Uwe82 Controls of my dlg do not have XP style.
Hi all, Its dialog based MFC application. My problem is, controls in my dialog do not have XP style. But in VC++ IDE's design mode, all buttons, edit boxes have XP style. I hope you understood what I asked, otherwise send me your mail-id I can send dialog's appearance in BMP image format. Thanks. :) Purusothaman A Thank you all. But this works only with unicode support. In non-unicode, dialog loses its XP style. Why so :) Purusothaman A You are missing a manifest for your application See using Windows XP Visual Styles Normally in Visual Studio 2005, when you create MFC applications, from the MFC Ap ...Show All
r3ganc DLL generated but related import library is missing?
Hello everyone, I am building a DLL file. But the related import library file .lib is not generated. I am using Visual Studio 2003. What points should I check in order to generate the import library file thanks in advance, George You need to either specify a module definition file (.def) or have at least one export (e.g. via __declspec(dllexport) or via the /EXPORT switch - either on the command line or in a ".drectve" section) If you have the linker should say something along the lines of "Creating Library xy.lib and object xy.obj". You should see the linker output in your build log file. -hg I like to specify the .dll file to be at some d ...Show All
naiveinVB Conversions string <-> int in C
Hi everyone! Does anyone know how to convert a string to an int and vice versa in C (not C++, only in C) I need it because I have to create txt files incrementally, whose names are 1.txt, 2.txt, ...etc. Thank you very much! Yes, you're right! It was a problem of space. Thank you very much Viorel There's no string type in any standard C that I'm aware of. Are you referring to a char[] * I think you should consider atoi , strtol , sprintf and sscanf functions. For example: char filename[. . .]; int number = . . .; sprintf(filename, "%i.txt", number); I hope this helps. &nbs ...Show All
toniSQL 64b development: Huge problem with VS2005 on a 32b OS
Hi, I've just discovered this weird bug in VS2005: when compiling and linking my application with the x64 platform target on a computer running Windows 2000, the executable can't be run on a Win64 computer. I've spent a lot of time trying to solve this pronlem, and I found the following: - by using Depends, I found that it's the "exported symbols" table that's invalid in these files, - it seems to be related to the Embed manifest option, because disabling it will generate valid executables and dlls, - the problem doesn't happen if I link the file on a Win 64 computer. So it seems that the Embedding process is not correctly done for 64 bit executables on 32 bit computers. By searching for this problem on the internet, I found that - some us ...Show All
sharpMoon How many users still develop with Visual C++ 6 or 7.0?
Hello, We are developing a SDK for our tools and provide libraries for Visual C++ 6, 7.0, 7.1 and 8.0. Since it is quite difficult to maintain 4 versions, I am wondering if it makes sense to discard libraries designed for Visual C++ 6 and Visual C++ 7.0 and keep only 7.1 and 8.0 Does someone know what is the percentage of VC6, 7.0, 7.1 and 8.0 currently on the market Thank you! Laurent Yep, that sounds about right for both my own experience and what I see at these forums. The key issue here though is: how many of your customers are going to get ticked-off because you forced them to shell out $750 bucks to buy VS2005 and spend the time to learn it. The latter dwarfing the out-of-pocket ...Show All
VuaCorona How to close a file safely no matter whether the file is closed or not?
How to close a file safely no matter whether the file is closed or not I hope that some expert can give me some sample for this small problem. Thanks. Folks on the newsgroups at http://msdn.microsoft.com/newsgroups should be more familiar with such issues. OTP Thanks, Ayman Shoukry VC++ Team ...Show All
AdeptBlue Missing icons on MDI child windows
Having written code to create MDI master and child windows using Win32 API, I have discovered that when using the application under the Windows XP theme, icons assigned to the MDI child only appear when the child is maximized. When the child is minimized or normalized, a white space appears where the icon should be. The icon is assigned using - SetClassLong(widgets[1].hwnd, GCL_HICON, (LONG)geeicon); The icons appear using the same code using Windows 2000 and Windows XP, classic theme. Also if you start the application using classic theme and then change to XP theme the icons stay attached to the child windows. It is only if you start the appication in Windows XP theme that the icons are missing. Any ideas ...Show All
visualbasicming Get the line of code something was executed on.
Language: C++/CLI .NET ---------------------------------- When you write an application and it throws an error it usually displays an error dialog. In this dialog it contains a description and a detailed report. In this detailed report it contains the line of code that the error was thrown on. What I want to do is get the line of code anything is executed and display it in my application. So for example, I want to show what line of code my function was called on and display it in a report to the user. Is there anyway to do this without hard coding it into the code (There must be since it is done in error dialogs, but I mean, how is it done ) The phrase "line of code" is ambiguous since I am not sure if you want the source ...Show All
srinimg Debugging release version in VS2005
I am debugging a complicated piece of software which takes quite a long time to run until it reaches the point which I have to investigate. Running debug version from debugger is too slow as it takes up to few hours to run until I get it to the point of the problem. I tried to compile the release version and run it from the debugger. Interestingly I can only see some variables (usually local function ones) in the watch window. The "this" variable for some reason is always shown as NULL. I also can not see values of variables of functions that are deeper in the stack. And finally my debug visualizers do not work. Project properties of debug and release versions seem to be almost the same (obviously _DEBUG directive is missing in r ...Show All
Mr_White Retrieving bitmap pixel dimensions
Hi, How can I retrieve the pixel dimensions of an HBITMAP object without using MFC Thanks. ---Dan Use the GetBitmapDimensionEx function. Please limit your use of this forum for its intended scope: C++ language issues. This question is best asked here: http://msdn.microsoft.com/newsgroups/default.aspx dg=microsoft.public.win32.programmer.gdi&lang=en&cr=US Try int GetObject( HGDIOBJ hgdiobj , // handle to graphics object int cbBuffer , // size of buffer for object information LPVOID lpvObject // buffer for object information ); and pass in a pointer to BITMAP structure. The pixel dimensions to the bitmap will be stored there. ...Show All
Juco Can't quite figure out error LNK2001
Hi, I am hoping someone with sharper eyes can help me with this error I am getting. I know it is probably something that I overlooked like missing required function or different argument types to a function, etc, but I just can't quite get around to actually pin-pointing the problem after having spent two days on this. :-( Thx in advance. Linking... VanillaOptions.obj : error LNK2001: unresolved external symbol "public: virtual class BaseOption * __thiscall OptionFactory<class BaseOption,class EuropeanCall>::CreateOption(void)" ( CreateOption@ $OptionFactory@VBaseOption@@VEuropeanCall@@@@UAEPAVBaseOption@@XZ ) C:\tmp\CPP\Calvin\MC_VS_2005\MC\Debug\MC.exe : fatal error LNK1120: 1 unresolved externals Build log was s ...Show All
CFIG Syntax for calling down the hierarchy for virtual property or event of CLR class
I have three CLR classes, let's call them Base, Derived, and MostDerived, with Derived derived from Base and MostDerived derived from Derived. The Base class has a virtual property and a virtual event. The Derived class does nothing with this property and event but the MostDerived class overrides each, and attempts merely to call down the hierarchy: ------------------------------------------------------------------ ------------------------------------------------------------------ ref class Base { public: // Constructor, destructor, member functions etc. virtual property int AProperty { int get() { return dAProperty; } void set(int value) { dAProperty = value; } } virtual event System::EventHandler ^ AnEvent { public: void add(System::Ev ...Show All
Kim Carlsen How to get the local time in miliseconds
Dear All, using win32 C++, I just want to know what is the usual way to get the local time in the format "hr:min:sec.milisec" Your help is much appreciated regards Bassam Someone else put the answer a bit earlier... You can use "GetLocalTime" function to get the local time. it will return the local time information in SYSTEMTIME structure passed to the funciton. please see the sample snippet SYSTEMTIME sysTime = {0}; GetLocalTime( &sysTime ); printf("%d:%d:%d:%d", sysTime.wHour,sysTime.wMinute,sysTime.wSecond,sysTime.wMilliseconds); Hi, If it is a win32 application , no header file is required. If it is a win32 console applica ...Show All
glx2074 createprocess based FTP fails when command file contains wildcard character
All, Newbie, need your expertise and insite on problem I am facing. createprocess based FTP fails when command file contains file name with wildcard character ('*') to refer dynamic file name, as the file name will have datetime stamp added at the end. eg: prod_ftp_01042006112234 ---> prod_ftp_*. Below code snippet (FTPClient.cpp) contains FTP client and FTP call. It works fine when file name doesn't contain wildcard char (*), but file transfer (FTP) fails only when file name has * at the end i.e. prod_ftp_*. No error being reported from FTPClient.cpp Same FTP command (ftp -s:FTP_CMD_File,FTP_Server) works fine in command prompt. But it fails at runtime from FTPClient.cpp and no error reported. Please let me know ...Show All
