|
Say I have a CString object strMain="AAAABB DDBB DDDAA"; I also have two smaller strings, say strSmall1="BB"; strSmall2="DD"; Now, I want to replace all occurence of strings which occur between strSmall1("BB") and strSmall2("DD") in strMain, with say ...
Started by Varun Mahajan on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
That, of course, assumes you want to replace all the occurrences in the main string -- if you only want to replace the ....
If curlocation matches string strsmall1 save index break loop over remaining string replace till curlocation.
|
|
I need to replace all WinAPI calls of the
CreateFile, ReadFile, SetFilePointer, CloseHandle with my own implementation (which use low-level file reading via Bluetooth). The code, where functions will be replaced, is Video File Player and it already works...
Started by Omega on
, 7 posts
by 7 people.
Answer Snippets (Read the full thread at stackoverflow):
Test that the application.
I'd rather search and replace all to the original APIs, and replace these with calls to your new wrapper functions.
Disclaimer: I think doing this is ugly and I wouldn't do it .
|
|
Std::auto_ptr is broken in VC++ 8 (which is what we use at work). My main gripe with it is that it allows auto_ptr<T> x = new T(); , which of course leads to horrible crashes, while being simple to do by mistake.
From an answer to another question...
Started by Daniel Sönnerstedt on
, 8 posts
by 8 people.
Answer Snippets (Read the full thread at stackoverflow):
Edit: Please find a related discussion here: http://stackoverflow.com/questions/197048/idiomatic-use-of-stdautoptr-or-only-use....
It will be the preferred smart pointer in upcoming C++ standards (is in TR1 already) .
Use boost::shared_ptr/boost::scoped_ptr.
|
Ask your Facebook Friends
|
Basically I have a bunch of unmanaged VC++ static libraries. And the VC++ GUI application which uses those and it is based on MFC. The goal is to replace the GUI app with the one done in C# instead but using all the same static libraries. The question...
Started by Ma99uS on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
However, if there is a lot of tight coupling between the GUI code and the libraries then this can get a bit... .
You would write a C++/CLI WinForms app and simply link in your static lib as per normal .
Yes, it is possible using C++/CLI for managed C++ code .
|
|
I'm encountering this error while compiling some old VC++ 6.0 source code.
error C2632: 'long' followed by 'long' is illegal
There's a part of the code that declares a long long int variable which caused the error. Does anybody know how I can fix this...
Started by jasonline on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
The long long data type, but if you have the necessary typedefs already you could replace "long long.
|
|
I'm using the Win32 function GetEnvironmentVariable to retrieve the value of a variable that I just created. I'm running Windows XP and VC++ 2005. If I run the program from within Visual Studio, it can't find the new variable. If I run it from a command...
Started by Amit G on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
To Tools...->options...->Projects and Solutions->VC++ Project Settings and set Show Environment.
|
|
Is there a Registry setting that I can look for to determine whether or not the Visual C++ redistributable is installed, whether standalone or as part of Visual Studio 2008? I know that I could launch the VC++ 2008 redistributable installer and let it...
Started by RobH on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
{8220EEFE-38CD-377E-8595-13398D740ACE}
64bit 30729.01
{0DF3AE91-E533-3960-8516-B23737F8B7A2}
VC++2008 (sp1)
{3C3D696B-0DB7-3C6D-A356-3DB8CE541918}
VC++2008 (original)
{FF66E9F6-83E7-3A3E-AF14-8DE9A809A6A4}
IA64 30729.01.
|
|
Hello everyone,
I'm working on old code that relies heavily on the exception specifications behavior described in the language standard. Namely, calls to std::unexpected() on exception specification violations of the form described below.
foo() throw(...
Started by Krugar on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Proper unit testing can replace your runtime checks..
|
|
Tamron 17-50 f2.8 VC
Is the tamron 17-50 f2.8 VC better than the canon 18-55 is kit lens?
In IQ and other areas?
I would go for for the canon 17-55 f2.8 is usm but I can't afford it and the sigma 17-50 hsm os f2.8 seams a bit expensive too.
Started by lucky_13 on
, 16 posts
by 8 people.
Answer Snippets (Read the full thread at talkphotography):
As for VC....
Personally focusing.
Yes it is better, the non VC version is better than the VC version.
|
|
How can I convert existing vcproj files to project files that the QT add-in to Visual Studio recognizes and treats as valid Qt projects?
Should I just bite the bullet and create new projects to replace the old ones, and then add existing code?
I am using...
Started by Morten Fjeldstad on
, 3 posts
by 2 people.
Answer Snippets (Read the full thread at stackoverflow):
The qmake manual is available here:
http.
And vice versa; If you have a .vcproj that has been generated by doing qmake -tp vc, then you can file using 'qmake -tp vc' on that .pro file.
|