Earlier quoted context omitted.
This was a major culture clash for me when I ended up working at a company that mainly sells Windows software. I do my best to stay objective about it and not jump to the conclusion that it's incredibly broken because of its hairiness.
Microsoft agrees that it's broken, which is why they're trying to get rid of the windows desktop and its legacy API's.
If you move your mouse continually the query may not fail. Do not stop moving
51–60 of 168 posts
Re: If you move your mouse continually the query may not fail. Do not stop moving
#52>> This problem has been reported when querying an ORACLE 7.3 data source by using the following ODBC drivers. Sqo32_73.dll is manufactured by Oracle Corporation. Microsoft makes no warranty, implied or otherwise, regarding this product's performance or reliability. Maybe not the fault of Microsoft?
Microsoft designed and built the OS and two of the three applications involved. And the third application was almost certainly built using Microsoft development tools according to Microsoft guidelines. How could this not be their fault?
Never mind that my callback violated the caller's threading model and that mutices introduce deadlocks when used incorrectly... They should fix the bug!
Edit: I guess what I was trying to say is that this part needs a huge "citation needed":
> was almost certainly built ... according to Microsoft guidelines
We don't know that at all. When you insert your code into another process, bugs in your code have the potential to destabilize that process. This discussion is extremely light on details but we cannot assume that the caller, rather than the callee, is at fault. If it's working correctly with another driver, I say, look at the suspicious driver, it's likely got a bug.
Re: If you move your mouse continually the query may not fail. Do not stop moving
#53Excel 2010 still relies on WinAPI's Fibers [1] (lightweight threads). In recent years the idea got popular again with Lua's co-routines and GO's goroutines.
So it is manually scheduled by the application, instead of relying on the OS.
In 2014, there is a lot of code in Excel that dates back to Excel 3 (1990). Excel 2010 still relied on the outdated MDI concept [2] that had been introduced with Win 3 and only one Excel instance/main window can run.
One can embed the Excel OLE component in one app [3]. As soon as the component get the focus it replaces the traditional menu bar with the custom drawn "ribbon bar". It looks weird out of place (Win9x style OLE app with ribbon bar). Office apps started with custom drawn UI objects with Office 97. It had these fancy toolbars and a italic window title [4] instead of the boring Win95 look that WinAPI provided.
[1] http://msdn.microsoft.com/en-us/library/windows/desktop/ms68... ; http://msdn.microsoft.com/en-us/library/windows/desktop/ms68...
[2] http://en.wikipedia.org/wiki/Multiple_document_interface
[3] e.g. using the sample apps that come "Inside OLE 2nd" book.
Re: If you move your mouse continually the query may not fail. Do not stop moving
#54And if you do not have a mouse ? :D
Re: If you move your mouse continually the query may not fail. Do not stop moving
#55I had this bug once about 10ish years ago when I was still a windows dev. Creating a 2nd window on a thread with a window already but then pumping it's main loop on a background thread can cause this. If you do that the loops get hooked to each other regardless of the thread pumping it. The child window has to wait until the parent window forwards the event for the second thread to pop it off. A mouse move will send…
Draining the message queue from a thread that doesn't own it makes absolutely no sense to me ... Does that actually work? Wouldn't you see the messages on the original thread's pump too? I thought the way it worked is each thread with ui objects has a queue, and SendMessage et al. will insert into the owning thread's queue. It took me a while to parse what you are saying, did you pass the hwnd into GetMessage from the other thread and that somehow convinced it to peek at another thread's queue?
Re: If you move your mouse continually the query may not fail. Do not stop moving
#56This is a 11 year old knowledge base article for a bug in a product (Excel 97) that saw the light in 1997, that is 17 years ago. Yes, the second workaround is kind of hilarious, but let's not draw too many far-fetching conclusions from it. I believe many of us have seen crazier bugs.
[1] https://support.microsoft.com/kb/276304
Edit: typo
Re: If you move your mouse continually the query may not fail. Do not stop moving
#57Re: If you move your mouse continually the query may not fail. Do not stop moving
#58Re: If you move your mouse continually the query may not fail. Do not stop moving
#59Excel codebase is very old, most is still in recent versions. Excel 2010 still relies on WinAPI's Fibers [1] (lightweight threads). In recent years the idea got popular again with Lua's co-routines and GO's goroutines. So it is manually scheduled by the application, instead of relying on the OS. In 2014, there is a lot of code in Excel that dates back to Excel 3 (1990). Excel 2010 still relied on the outdated MDI con…
Re: If you move your mouse continually the query may not fail. Do not stop moving
#60I clearly remember old times with Windows 98/ME, where if you keep moving mouse, long-running operations like directory coping would be faster, thanks to CPU power savings not kicking-in.
In the Windows NT series (4, 2000, XP, etc.) the sheduler gives the forground application an higher priority. It runs a longer CPU time than all other applications. This was probably also similar with Win 3 and 9x series but probably with many hacks and glue code on top of DOS.
Moving the mouse also prevented the screensaver, an application that would "save" the screen by drawing fancy graphics to prevent static phosphore burns on CRT monitor and slowed down the system