The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,839 other subscribers

Research list: Offline Blog editors that support WordPress.com

Posted by jpluimers on 2013/07/19

Some links for my research list on offline blog editors that support WordPress.com blogs:

–jeroen

Posted in Power User, SocialMedia, WordPress | Leave a Comment »

Delphi virtual constructors: example of the “Factory” design pattern (via: Stack Overflow)

Posted by jpluimers on 2013/07/18

I bumped into the below answer that I gave a while (what is 4 years in a developer’s life ) on StackOverflow.

It is about Delphi Design Patterns. Sepcifically the Factory Pattern, and explains how virtual constructors implement it.

They are one of the 3 corner stones on which the component based Delphi form designer and object inspector are built:

  • Virtual constructors
  • Properties (events are just a special form of property)
  • Run-Time Type Information.

So here it goes: Read the rest of this entry »

Posted in Delphi, Delphi 1, Delphi 2, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 3, Delphi 4, Delphi 5, Delphi 6, Delphi 7, Delphi 8, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Development, Software Development | 6 Comments »

C#: combining “adding `char` and `int` and “`a += b` means `a = a + b`, but `a += b + c` does not mean `a = a + b + c`”.

Posted by jpluimers on 2013/07/18

A while ago, I wrote about .NET/C# duh moment of the day: “A char can be implicitly converted to ushort, int, uint, long, ulong, float, double, or decimal (not the other way around; implicit != implicit)”.

There is another duh moment having to do with the various C# operators like += which is being described as being

a += b

is equivalent to

a = a + b

You might think that this also holds:

a += b + c

is equivalent to

a = (a + b) + c

But Eric Lippert has explained this is not the case: it is equivalent to:

a = a + (b + c)

In his explanation, he also shows the confusion can get you very surprising results if you mix string, chars and ints in the expression: depending on the statement and ordering, you either concatenate characters, or add ints to characters.

He also recommends you should not do concatenation: either use String.Format, or StringBuilder. I totally agree with that.

Recommended reading!

–jeroen

Posted in .NET, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, Development, Software Development | Leave a Comment »

2 More Old Micro Cornucopia issues on BitSavers from 1986

Posted by jpluimers on 2013/07/17

2 more issues got on-line both close to a 100 pages each:

So the only issues missing are #28, #30 and #31.

–jeroen

via: More Old Micro Cornucopia issues on BitSavers from 1987 and 1988 « The Wiert Corner – irregular stream of stuff.

Posted in Assembly Language, BitSavers.org, C, C++, Development, History, Pascal, Software Development, Turbo Pascal, Turbo Prolog, x86 | Tagged: , | 1 Comment »

Lots of projects did not get it yet, but for connecting to SQL Server: RIP OLE DB

Posted by jpluimers on 2013/07/17

I still see a truckload of projects that connect to SQL Server do this using OLE DB or the Native SQL Client.

All OLE DB access to SQL Server has been deprecated, not only from regular access, but also from SSIS.

These are the only ways you should connect to SQL Server:

  • SqlClient (managed code)
  • JDBC (Java)
  • ODBC (for native code)

For instance, these have been deprecated (for each one, I linked to the oldest SQL Server version where they were made available for):

  1. SQLOLEDB
  2. SQLNCLI
  3. SQLNCLI10
  4. SQLNCLI11
  5. SQLXMLOLEDB.3.0
  6. SQLXMLOLEDB.4.0

–jeroen

via: RIP OLE DB.

Posted in Database Development, Development, SQL Server | Leave a Comment »

Igor Ostrovsky: C# – The C# Memory Model in Theory and Practice;

Posted by jpluimers on 2013/07/16

Just found out that Igor Ostrovsky wrote two really nice articles on .NET memory management as part of his great series of other .NET articles there:

  1. C# – The C# Memory Model in Theory and Practice.
  2. C# – The C# Memory Model in Theory and Practice, Part 2.

–jeroen

Posted in .NET, .NET 1.x, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0, .NET 4.5, Development, Software Development | Leave a Comment »

PowerPoint high cpu usage

Posted by jpluimers on 2013/07/15

Every once in a while, a hidden POWERPNT.EXE consumes 100% of one CPU core (on a single core, that is deadly, on a multi-core system it drains your battery pretty fast).

This was the cause:

One reason is you have preview pane enabled and have selected a PowerPoint File. To preview it an invisible copy of PowerPoint is opened and may not close when you deselect. This doesn’t normally use much cpu though.

–jeroen

via PowerPoint high cpu usage.

Posted in Office, Power Point, Power User, Windows | Leave a Comment »

Freaking out (not only) mobile app users – xkcd: QR Code

Posted by jpluimers on 2013/07/12

xkcd: QR Code titled “Remember, the installer is watching the camera for the checksum it generated, so you have to scan it using your own phone” is not only freaking out mobile app users (:

The fun starts when putting http://imgs.xkcd.com/comics/qr_code.png through a QR decoder

The QR paradox: is an infinite loop impossible?

–jeroen

via: xkcd: QR Code.

Yeah, yeah 1237: QR Code – explain xkcd got it too: ZXing will parse http://imgs.xkcd.com/comics/qr_code.png fine, then gets you to http://xkcd.com/1237/scan/ which contains http://imgs.xkcd.com/comics/qr_code_loop.png which parses fine.

Posted in Comics | Leave a Comment »

Which OS X version has which name? (via Wikipedia, the free encyclopedia)

Posted by jpluimers on 2013/07/12

Though Apple prominently advertises with the OS X name, they give Mac users a hard time finding it:

None of the built in options like “About this Mac” or “Software Update…”  tell you the OS X name. They only tell you the OS X version number.

So I grabbed this list from the OS X – Wikipedia, the free encyclopedia. article:

  1. Public Beta: “Kodiak”
  2. Version 10.0: “Cheetah”
  3. Version 10.1: “Puma”
  4. Version 10.2: “Jaguar”
  5. Version 10.3: “Panther”
  6. Version 10.4: “Tiger”
  7. Version 10.5: “Leopard”
  8. Version 10.6: “Snow Leopard”
  9. Version 10.7: “Lion”
  10. Version 10.8: “Mountain Lion”

This list was correct at the time of writing, but Wikipedia probably keeps a better track at updating than I do, so after publication my list might lag behind.

–jeroen

via OS X – Wikipedia, the free encyclopedia.

Posted in Apple, Mac, Mac OS X / OS X / MacOS, Mac OS X 10.4 Tiger, Mac OS X 10.5 Leopard, Mac OS X 10.6 Snow Leopard, Mac OS X 10.7 Lion, OS X 10.8 Mountain Lion, Power User | Leave a Comment »

Rode plekken/blaren na een landelijke picknick in de zon: Berenklauw, Fototoxiciteit en Fytofotodermatitis (via: Wikipedia)

Posted by jpluimers on 2013/07/11

Afgelopen weekeinde waren we met een groep kanovaren rondom Lisse/Sassenheim. We hadden lunch aan de rand van een stukje akker waar we relatief makkelijk uit de kano’s konden komen.

Een soort landelijke picknick in de zon: altijd leuk om te doen.

Maandagavond werd ik door 1 van de deelnemers gebeld: hij had een enorme rode jeukende vlek op zijn arm met allemaal blaren, en dacht dat hij brandnetels geraakt had.

Die stonden er niet, bovendien gaat het na aanraking van brandnetels meteen branden en deze plek was pakweg een dag later gekomen. Dus het moest iets anders zijn, maar wat?

Hij is ermee naar de huisarts geweest die tot de conclusie kwam: aanraking van Berenklauw in combinatie met blootstelling aan zonlicht. Dat veroorzaakt namelijk Fytofotodermatitis door Fototoxiciteit, en kan bij veel mensen enorme brandplekken geven. Read the rest of this entry »

Posted in About, LifeHacker, Personal, Power User | Leave a Comment »