The Wiert Corner – irregular stream of stuff

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

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

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

    Join 1,862 other subscribers

Archive for 2015

Translating non-English error messages into English

Posted by jpluimers on 2015/08/06

For a long time, I’ve persuading people to install English versions of their operating systems (especially on server side) at least for some parts of their environment.

The main reason is that searching for English error messages gives you a much bigger chance of finding the cause than non-English ones.

I’m still standing by that recommendation, but life has become a bit easier because of these two sites that offer quite good translations of Windows Error messages in many languages to English:

I like the latter a bit more because of the overview, but the former more because of the catalog.

The way I landed there was because of a search for “Cannot SetData on a frozen OLE data object” which I bumped into for one of my C# .NET projects.

–jeroen

Posted in .NET, C#, Development, Power User, Software Development, Windows, Windows 7, Windows 8, Windows 8.1, Windows 9, Windows Server 2003, Windows Server 2003 R2, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2, Windows Vista | Leave a Comment »

Difference Between Int32.Parse, Convert.ToInt32, and Int32.TryParse – CodeProject

Posted by jpluimers on 2015/08/05

Every C#/VB/.NET developer should read Difference Between Int32.Parse, Convert.ToInt32, and Int32.TryParse – CodeProject.

Then also read TryParse with default values.

It is all about handling values that are not Integers, Overflow values and Nulls. There are subtle differences, in the handling of the methods, and the exceptions they could throw: ArgumentNullException, FormatException and OverflowException.

Finally read all about the NumberStyles enumeration, IFormatProvider interface and CultureInfo (especially the difference between InvariantCulture, CurrentCulture, CurrentUICulture and InstalledUICulture).

Because getting your conversions right matters.

–jeroen

Posted in .NET, .NET 1.x, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0, .NET 4.5, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, C# 6 (Roslyn), Development, Mono, Mono for Android, Prism, RemObjects C#, Software Development, VB.NET, VB.NET 10.0, VB.NET 11.0, VB.NET 7.0, VB.NET 7.1, VB.NET 8.0, VB.NET 9.0 | Leave a Comment »

Easy 6502 by skilldrick: an ebook tutorial to learn 6502 assembly with embedded simulator

Posted by jpluimers on 2015/08/04

A while ago, Alan Cox write a G+ post pointing me to Easy 6502 by skilldrick. The last couple of weeks I finally found time to play with it:

It is a tutorial ebook by Nick Morgan with examples and a play ground based on the adapted JavaScript 6502 assembler and simulator right integrated into a github.io site.

From the perspective of learning assembly language to get a grasp of thinking at the lowest computer abstraction, it is an ideal tutorial: the 6502 is a very simple 8-bit processor with only 3 registers. These restrictions make programming fun.

These are the topics covered:

This is what Alan thinks about it:

… some of the other 6502 tutorials

This one is really really neat – bit more basic than the bits I need to brush up on but really nicely done.

skilldrick.github.io/easy6502/Easy 6502.

via:

Posted in 6502, 6502 Assembly, Assembly Language, Development, History, JavaScript/ECMAScript, Scripting, Software Development | Leave a Comment »

Windows security updates breaking old software: to upgrade or not (that is not really a question).

Posted by jpluimers on 2015/08/03

Windows Security updates sometimes break old software.

In this case it was an older InstallShield version (not even sure it was 2012), breaking with this message when security updates like KB2949927,  KB3004394 or KB3033929 are installed:

ISDEV : error -6003: An error occurred streaming ‘<path>\DiskImages\DISK1\<filename>.isc’ into setup.exe.

An earlier security update KB2962872 even crashed InstallShield 2012 and 2013 during startup.

It raises the issue if security updates are more important than upgrading your tool-chain. For less flexible organisations (not limited to large ones; small ones can be just as inflexible for instance when an upgrade also requires time or skills to be acquired) this can impose a serious problem.

Where Windows XP let you choose which updates to install and when, Windows 7 and 8 became more mandatory (installing security updates automatically even rebooting). Rumour was that Window 10 does not even let you uninstall security updates any more, but that has feature has been removed.

–jeroen

via:

 

Posted in Development, Install Shield, Installer-Development, Software Development | 4 Comments »

Excel: replace function is named SUBSTITUTE – via: Stack Overflow

Posted by jpluimers on 2015/08/03

Thanks DarkAjax for answering this:

what you’re looking for is

=SUBSTITUTE(A2,"Author","Authoring")

Will substitute Author for Authoring without messing with everything else.

I always forget that SUBSTITUTE is a synonym for replace.

There are REPLACE and REPLACEB, but these replace content of a cell, not of a string.

–jeroen

via Excel: replace part of cell’s string value – Stack Overflow.

Posted in Excel, Office, Office 2003, Office 2007, Office 2010, Office 2013, Power User | Leave a Comment »

Marktplaats zonder topadvertenties – Chrome Web Store

Posted by jpluimers on 2015/07/31

Marktplaats zonder topadvertenties – Chrome Web Store.

Posted in Power User | Leave a Comment »

Never underestimate the inability for people in charge to understand how tech works.

Posted by jpluimers on 2015/07/31

LOL:

Never underestimate the inability for people in charge to understand how tech works.

as commented by Asbjørn Heid.

–jeroen

via: Als Folge der spanischen Leistungsschutzgeldgesetzes hat Google in Spanien….

Posted in Fun, Quotes | Leave a Comment »

logparser – Wikipedia, the free encyclopedia

Posted by jpluimers on 2015/07/31

Thanks to Sebastian Gingter for pointing me at Logparser:

Logparser […] powerful, versatile tool that provides universal query access to text-based data such as log files, XML files and CSV files, as well as key data sources on the Windows operating system such as the Event Log, the Registry, the file system, and Active Directory. The results of the input query can be custom-formatted in text based output, or they can be persisted to more specialty targets like SQL, SYSLOG, or a chart.

Common use:

$ logparser [options] [SQL expression]

–jeroen

via logparser – Wikipedia, the free encyclopedia.

Posted in Development, IIS, Power User, Windows, Windows 7, Windows 8, Windows 8.1, Windows 9, Windows Server 2003, Windows Server 2003 R2, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2 | Leave a Comment »

Delphi: turn off column or line block selection mode – via: Default IDE Shortcut Keys; Delphi Programming

Posted by jpluimers on 2015/07/30

The Default IDE Shortcut Keys – Delphi Programming was a good starting point to find out how to disable column or line blocks.

Since the table there is incomplete (even the Embarcadero documentation is wrong as some shortcuts can turn on and off a mode), here are the relevant shortcuts keys:

Ctrl + O + C Turns on/off blockcolumn selection mode Delphi 5 and up
Ctrl + O + K Turns on/off block selection mode Delphi 5 and up
Ctrl + O + L Selects current line (and turns off block selection mode) Delphi 5 and up

This is especially useful when the block selection is stuck (this happens every now and then: it’s a known bug).

–jeroen

Posted in Delphi, Delphi 10 Seattle, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 5, Delphi 6, Delphi 7, Delphi 8, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | 6 Comments »

Repeating the same expression multiple in RegEx search, and replace it only one time – via: Stack Overflow

Posted by jpluimers on 2015/07/29

I’m really really glad that Lucas Trzesniewski has answered this:

While most regex flavours have roughly a similar syntax for the basic features, there is not a clear standard as to the syntax of the replacement strings. Some tools use \1 for referencing strings, others use $1 and so on.

As you use Notepad++, you should know it uses the boost library for its regex implementation, and it uses the Boost-Extended format string for the replacement pattern.

In particular, the placeholder for the nth capture group is $n.

And my comment:

Thanks a lot for that. I found a bit more information about back references and capture groups in various libraries on regular-expressions.info/replacebackref.html.

on my question: Read the rest of this entry »

Posted in Development, RegEx, Software Development | Leave a Comment »