Type: Posts; User: John E
Search took 0.12 seconds.
November 21st, 2015, 06:38 AM
Thanks 2kaud. I used your 2nd example (if it's good enough for winnt.h, it's good enough for me!)
Do you happen to know which version of Visual Studio introduced these macros? The library I'm...
November 20th, 2015, 12:24 PM
I'm working on a cross-platform library which is supposed to be buildable with MSVC (and always has been, up until now). But after a git update today I'm seeing a lot of errors which seem to boil...
October 23rd, 2015, 08:53 AM
Thanks ahppdin. I just installed AdwCleaner but it didn't change anything. Previously, I'd already run Microsoft Security Essentials but that didn't change anything either.
All my instincts are...
October 23rd, 2015, 08:03 AM
It doesn't seem like anyone else has seen this message :(
So has anyone here got a reliable means of contacting Google (so I can find out if it's genuinely coming from them?) I've tried contacting...
October 2nd, 2015, 05:30 AM
I've got several PCs running different versions of Windows. I tend to use Internet Explorer as my preferred browser and I've set it up to use Google as its home page. But for about a month now, one...
September 24th, 2015, 12:29 PM
Thanks 2kaud. Sorry for the delay in replying.
I did some research into this and while you're right (i.e. a c'tor taking FILE* isn't officially part of the standard) it's often supported as a...
September 19th, 2015, 11:47 AM
After some further experiments I've realised that (in MSVC at least) std::filebuf does exist and it offers a c'tor of type filebuf::filebuf(FILE*). So if that's available outside of MSVC my problem's...
September 19th, 2015, 06:51 AM
Is it possible to attach an istream object to an already opened file handle or FILE* (so I could read the file contents into my object?)
I discovered recently that ifstream has a c'tor for this...
September 14th, 2015, 03:05 PM
Hi Philip. The code was originally written for gcc (which I don't have a copy of). It didn't occur to me that ios::binary might be supported by gcc (even if it just gets ignored). Are you pretty...
September 14th, 2015, 09:29 AM
That's a good suggestion OReubens but I already tried it yesterday. I'm not sure if it'd work in more recent versions of MSVC but for the version I'm using (VC 8) it gives me:-
September 14th, 2015, 05:34 AM
This is a follow-up regarding an issue I've had using ofstream in a cross-platform app (I started an earlier thread but I prematurely marked it as 'resolved') :cry:
For creating an ofstream (in...
September 12th, 2015, 03:42 AM
Hi superbonzo. It looks like our posts overlapped. To fill in the background... I'm working on a cross-platform app which uses the glib/gtk toolset. These use UTF8 to represent file paths etc. So...
September 12th, 2015, 03:35 AM
Eventually I did manage to figure this out and yes - most of my problems were due to the fact that I hadn't realised that ios and ios_base are already in namespace std
The last remaining problem...
September 11th, 2015, 11:39 AM
After some further reading it seems like the identifier ios_base is itself in namespace std - So I'm guessing that int some_var = std::ios_base:: out; might have worked here..?
Does that also...
September 11th, 2015, 03:29 AM
Thanks superbonzo. I made a start on this yesterday but it's turning out to be incredibly difficult (and all I've done so far is try to derive a class from std:: ofstream!!). Here's an example c'tor...
September 10th, 2015, 02:35 AM
Any other libraries that offer good stream classes? Libboost offers an iostream class but even that doesn't have a function to connect to an already opened file (not AFAICT anyway). And I'm not sure...
September 9th, 2015, 04:10 AM
Thanks 2kaud. At the moment I'm using MSVC8 while other colleagues are using various mixtures of mingw and gcc - so C++11 isn't an option for us yet. I must admit I've been quite dismayed to realise...
September 9th, 2015, 03:21 AM
Groan... it looks like I jumped the gun on this one. I've been told that the c'tor which takes a file descriptor isn't universally supported (it's Microsoft specific). So is there any standard way to...
September 8th, 2015, 03:00 AM
Oops - should have looked on msdn
The file gets flushed but is only closed if it got opened by the ofstream object itself.
September 7th, 2015, 02:51 PM
When creating an ofstream I can specify the path of a file to be opened, plus some info about it's open mode etc. ofstream's d'tor will then flush (and close) the file when the object goes out of...
August 30th, 2015, 05:28 AM
Thanks guys. As an aside, do either of you know if it's possible to enable Aero Glass in Windows 10? According to an article I read, the beta version offered a registry key to enable it - but if you...
August 29th, 2015, 01:44 PM
Thanks 2kaud. I tried that link and it seemed to install quite smoothly. The only issue I've noticed so far is that I can't for the life of me find Add/Remove Programs any more (or even Control...
August 29th, 2015, 07:14 AM
For the past few weeks, every time I booted up I've been seeing a 'Windows' icon in my task bar and a message asking if I want to upgrade to Windows 10. I haven't heard anything bad about it so a...
August 13th, 2015, 10:51 AM
Thanks again. Alternatively, could I declare the function using __declspec(noinline) ?
August 13th, 2015, 04:32 AM
Thanks O'Reubens. For MSVC8 I used your last example and it compiled okay. Just one question though... will it return a value? The original code did this:-
return (static_cast<uint64_t>(edx) <<...
Click Here to Expand Forum to Full Width
This is a Codeguru.com survey!