Saturday, October 22, 2005

Blogger Backup with Tortuga Blogger 2.0 .NET Component

Not having a life, I just gave the Open Intelligence Data ™/Tortuga Blogger 2 .Net component that I posted about here, Free Blogger 2.0 .NET Component, a quick try.

The MSI was a simple file copy and appears to be safe. I do need to run reflector on it to confirm there’s nothing bad in there though (said after I’ve already used the component… Dogh!)

Using it is very easy. And it could almost be perfect as a Blogger backup. The only problem is that it can only access your last 100 posts!

Damn, so close. And it’s almost perfect too. The BlogPost.SaveToXml is great. It does seem to have an nbsp issue, so the XML won’t load into IE. But that’s easy enough to solve.

All I need is a way to get my TotalPosts and then a method to get a post by TotalPostIndex. I wonder if this is a problem with the Blogger API and not this component? Time to do more R&D. I’d really rather use the API to backup my blog instead of spidering it…  

Anyway, below is a very quick and dirty VB7.1 code snip that shows how to use Tortuga Blogger 2 .Net component to log into Blogger, get your first blog and download to xml all your recent posts (up to the most recent 100).

    Dim Blogger As New Tortuga.Blogger

    Blogger.LoginName = "Put your Blogger User ID Here"
    Blogger.Password = "Put your Blogger Password Here"

    If Not Blogger.Login Then
      MsgBox(Blogger.LoginFailReason)
      Blogger.Dispose()
      Return
    End If

    Dim blog As Tortuga.Blog = Blogger.GetBlogByIndex(0) 'Get 1st blog
    If blog Is Nothing Then
      Blogger.Dispose()
      Return
    End If

    blog.DownloadRecentPosts()

    Dim RecentPostCount As Integer = blog.NumPosts

    For BlogPostIndex As Integer = 0 To RecentPostCount - 1

      Dim blogpost As Tortuga.BlogPost = blog.GetPost(BlogPostIndex)

      blogpost.SaveToXmlFile("C:\test\" & BlogPostIndex.ToString("000") & ".xml")

      blogpost.Dispose()

    Next

    MsgBox("Done")
    blog.Dispose()
    Blogger.Dispose()

MSMQ Queue Message Count in VB6

Today I need to find a simple and easy way to get the number of messages in a private MSMQ Queue on a remote server.

After googling for a while, there seems to be three ways.

  1. MSMQ 3.0 COM Object (via the MSMQManagement and MSMQQueueManagment objects)

  2. WMI

  3. MSMQ Admin API

A. WMI is cool, but I’d rather a more direct method.

B. The MSMQ Admin API is not fun (to say the least) to call directly from VB. A C++ wrapper would really be needed. So this method is tabled for now.

C. MSMQ 3.0 COM is very cool, but requires XP or 2003 (and we’re still on Win2K in production. But we are moving toward XP in the very near future…)


So MSMQ 3.0 COM looks like the only viable method given the time and resources available. And it will give our XP rollout that much more oomph…


Here are come relevant links I found while searching, as well as a VB6 MSMQ 3.0 queue message count sample.

Counting messages in Queue - the .NET version
Counting the number of messages in a queue
How to GET the message count of MSMQ in .NET without Performance Counter?
FILE: MSMQ Local Admin API
MSDN - Message Queuing COM Components

VB6 Sample using MSMQ 3.0 (XP and Win2003)

‘Add Reference to “Microsoft Message Queue 3.0 Object Library”

Private Function GetPrivateQueueMessageCount(sServerName as string, sQueueName as string) as Long

  Dim Mgmt As MSMQManagement
  Set Mgmt = New MSMQ.MSMQManagement
      
  Mgmt.Init sServerName, ,"DIRECT=OS:" & sServerName & "\PRIVATE$\" & sQueueName
  
  GetPrivateQueueMessageCount = Mgmt.MessageCount

End Function

Sonny, the Uber-Cat

Do you know what this is?

“ujjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj
jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj
jjjyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
yyyyyyg;///////////////////////7jjjjjjjjjjjjjjj”


It’s the IM message my cat just sent… LOL

I had am IM window open, where my son and I were chatting about a homework assignment. Finally got up and walked the 10 feet separating us so I could see just what the heck he was talking about...

As we talked, all of a sudden an IM window popped up with the above message. From me! Wondering what the heck, we ran back to the living room.

Standing on my keyboard, very proudly, was Sonny the IM’ing cat.

I’m just glad he didn’t send an email to someone at work. Damn cat….  ;)

Team Foundation Beta 3 Virtual PC Coming Soon

Buck Hodges : Team Foundation Beta 3 Virtual PC is headed your way

"The beta 2 Virtual PC image was hugely popular. The new Team Foundation beta 3 VPC image is now making its way up to MSDN. So, later today or Monday you'll be able to download and run a single-server and client beta 3. Just make sure you have plenty of RAM since you'll be running everything on one machine (say 2GB+). "

Rock on!

I just checked the MSDN subscription site and didn't see it, so it looks like Monday is the day...

Related Past Post XRef:
MSDN Subscriptions - Visual Studio 2005 Team System Beta 2 VPC

SQL Server 2k5 "SELECT TOP" Bug

Beware! SELECT TOP is BUGGED!

"Yes it is true. And this bug has just been discovered by me and confirmed by the Query Optimizer Project Lead (Conor Cunningham) himself, that i have the chance to meet at SQL PASS 2005.

He has been very kind and after I exposed the problem to him, after a little bit of suprise :-), in few days he confirmed that in some circustances SET ROWCOUNT, which is deprecated, is faster than the usually better SELECT TOP.

You can test it yourself, downloading the script right here. I must say that the problem only shows when you need to limit the rows returned by your query while you're sorting over a colum with no index. At least this is my experience. Fortnately this is really an uncommon scenario so the bug is not really a tremendous one, but ouy should better know it since using SET ROWCOUNT under this cirumnstances can speed up your query by more that 3/4 times!

I've been also confirmed that this bug will not be fixed in the forthcoming version of SQL Server 2005 but will be fixed in the first service pack. ..."


An interesting bug.

Given the reported speed impact, this is something I need to look into when we move to SQL 2k5... (Which will be agressive as there are some features in SQL 2k5 that I can use ASAP).

Thursday, October 20, 2005

FrozenTech's LiveCD List

FrozenTech's LiveCD List

298 (at this time) Live OS CD's & DVD's. 98% Linux CD's, with Dos, Windows, BSD and Solaris also in the mix.

What's nice is that each has a summary link as well as download links. Also what's cool is that each has been tagged with the categories it falls into. And the list can be filtered by these categories.

So if you are looking for Forensic (7), Gaming (11), Desktop (138), Development (13), etc, you can easily find them here.

Free Blogger 2.0 .NET Component

Blogger 2.0 .NET Component (free)

"This is a free .NET component that can be used in C# and VB.NET applications, as well as in ASP.NET web sites. It provides a Blogger API for managing blogs at blogger.com. It can create new posts, edit existing posts, delete posts, and download blog posts. ..."

Very cool. And if you like this, you have to check out all the other free tools on the Open Intelligence Data ™ home page.

There are ActiveX and .Net libraries for Movable Type, Yahoo Site Explorer, Technorati, MetaWeblog, RSS, Atom, Social Bookmarking (i.e. del.icio.us), plus some more utilities (like a spider, domain info, web search, etc).

So pretty much tons of fun. It looks like a binary distrib only... Since it comes in MSI form only, I'm going to try and find some time to spin up a VPC to check it out first (or most likely I'll be lazy and just install it... sigh)

I wonder how hard it would be to whip up a Blogger backup utility with this? That was my first thought when I saw this. Based on the API docs it looks easy (famous last words).

As I've posted before, I've used htaccess WinHTTrack to download my site in the past. I've also used Acrobat's ability to grab web sites. Using Acrobat this last weekend to grab my entire site took about 40 hours and ended up with a 6K+ page PDF. I've pretty much hit the wall with that method... :

Gee another off time project? Imagine that! :)

(via del.icio.us/oazabir/.net/)

Component Workshop Releases Open Source Windows Forms Explorer Bar Control

Component Workshop

"Open Source Windows Forms ExplorerBar Control

Add stylish XP style ExplorerBar's to all you .NET applications.

Make use of FULL XP theme support, including custom theme classes and parts.

Drag and drop support that allows your end users to customize the gui at runtime.

Use any Windows Forms control as an ExplorerBar item allowing you to turn a simple explorerbar into a complex gui.

Download full source code and a sample application here.

NOTE : The download contains a Visual Studio 2003 solution and two VB.NET projects

Component Workshop have made this component free for any purpose and therefore take no responsibility for is usage or support, however community support if offered through the company forums. "


This is kind of cool...

While Explorer bars don't really float my boat, I do have users who do like them. And while there are about a billion of these available, this one is not only free but also VB.net OSS.

I think this is a smart approach, that I've also tried to encourage at my work. Release non-competitive advantage work/projects/utilities/code/etc as free or OSS to earn credibility, mind-share and good will.

Getting free stuff is cool. Getting cool free stuff is better. Getting cool free stuff with source is the best...

And guess what? It works...

The next time I need a product like Component Workshop sells, I will think of them early due to the good will they've earned in my mind by releasing this component as OSS...

(via The ServerSide.Net - Component Workshop Releases Open Source ExplorerBar Control

WinFX Sept CTP And Vista 5231

WinFX Sept CTP Will Not Install on Vista 5231 - ANSWER

"The WinFX Sept CTP will not install on 5231 rendering this build of Vista ... Rob Ralyea on the Avalon team that this build doesn't and will not have a matching WinFX version. The great news is that “we have since fixed this problem, so all future Windows Vista public releases will include WinFX with it.” Thank you! "

Thank god.

Wednesday, October 19, 2005

Coding Slave Author Is Job Hunting... (Or "Maybe I should take a close look at ...")

Coding Slave: The Blog: Q: What do you call a tired, middle aged programmer with an attitude?

"Q: What do you call a tired, middle aged programmer with an attitude?

A: Fired.

Let's cut to the chase. I got fired last week. That's right, the guy that wrote Coding Slave, Mr. 15 Years Experience in the woe and sublime of software development got fired-- ..."


Ouch.

Seeing something like this happen makes me look at my life, profession and behavior...

Double ouch...

Tuesday, October 18, 2005

Litigation Support Technical Standards, Free eBook

Free Document Helps Eliminate Issues with Litigation Technical Goods

"San Diego, California (PRWEB) October 17, 2005 -- Author and Litigation Support veteran, Mark Lieb bridges the gap between firm technical needs and vendor product in his free online document, Litigation Support Technical Standards. Located at www.ediscovery.org, the site provides a template of technical specifications for as many types of litigation software as possible along with file naming conventions and network standards.

LSTS is a technical supplement to Litigation Support Department – a book specializing in management of case technology, department operations and firm finance. While LSD provides management strategies, LSTS details the technical specifications needed to generate a consistent product regardless of vendor. There is also a “what not to do” section where errors relating to media labels, load files, transcripts, and general issues are illustrated and discussed. All examples are drawn from real life experiences and can help any firm or vendor avoid unnecessary headaches which delay review, productions and the efforts of litigators, paralegals and the Litigation Support Department technicians. ..."


Kind of interesting... Downloaded the PDF and will take a more detailed when I can.

Sunday, October 16, 2005

What comes after a Petabyte?

Binary Powers of Ten (10)

"1 bit =
1 byte =
1 kilobyte =
1 megabyte =
1 gigabyte =
1 terabyte =
1 petabyte =
1 exabyte =
1 zettabyte =
1 yottabyte =
1 ?1byte =
1 ?2byte =
1 ?3byte = "


Cool... I want a yodabyte hard drive (oh, it's "yottabyte"... ;)

(via digg - Beyond the Petabyte)

Friday, October 14, 2005

Writing Science Fiction and Fantasy Online Course

Welcome to Science Fiction and Fantasy Writing!

"Have you always harbored a secret (or not so secret) yearning to write? This course is designed to help you learn many of the skills you need to write successful science fiction and fantasy stories. You can use the skills you'll learn here in other kinds of storytelling, as well.

Whether you're trying to write for the first time, or have been at it for a while, you'll probably find some useful tips here. The course is intended mainly for younger (high school and middle school) writers, but it covers fundamentals you can build on no matter what your age. ..."


One of my secret dreams (which is no longer all that secret with this post) is to write science fiction...

(via Rod Trent at myITforum.com - Aspiring Sci-Fi writers...)

Determine Possible Row Size for SQL Server Table

How do I determine the row size of all tables in a particular DB?

"...

SELECT OBJECT_NAME (sc.[id]) tablename
, COUNT (1) nr_columns
, SUM (sc.length) maxrowlength
FROM syscolumns sc
join sysobjects so
on sc.[id] = so.[id]
WHERE so.xtype = 'U'
GROUP BY OBJECT_NAME (sc.[id])
ORDER BY SUM (sc.length) desc

..."


As I mentioned before I'm currently playing in Unicode land. I'm in the process of updating a number of SQL Server tables to support unicode/non-ascii text (i.e. varchar to nvarchar, etc).

Given than nvarchar's take twice as many bytes as varchar's, row length management is an important part of this conversion.

To help, I needed a quick way to get the existing possible row sizes for my tables. A quick google brought me the above SQL, which fit the bill perfectly...

And I'm sure I'll need it again, so in order to find it I'm posting it here.

Reference Manager for Visual Studio 2005

Reference Manager for Visual Studio 2005 RC

"If you are working with references (assembly or project references) in VS probably sometimes you have to do some annoying tasks:

Case 1) Where am I using this reference (i.e.: System.Data) in this solution?

Solution: I have to traverse all the projects in the solution and depending on the kind of project expand the references item or even worst open the properties dialog to see the references!!

Case 2) Remove a reference from multiple projects.

Solution: I have to go project by project removing the reference!!

Case 3) Add a reference to multiple projects

Solution: Project by project call to Add Reference dialog!!

Case 4) we have installed a new version of some assembly so we need to replace all references

Solution: You have to apply 1, 2 and 3!!!

So that I decided to make my life easier and I developed a tool called "Reference Manager"

You will have this tool available on the solution context menu. I tried to solve the above use cases. So now the solution for each case is easier. ..."


I had some "reference fun" the other day where a tool like this might have come in handy.

"Using WSUS without Active Directory"

Using WSUS without Active Directory - The Lazyadmin.com

"Windows Software Update Server (WSUS) is a great product that can be used to push out updates to your Windows computers. If you are deploying it in an Active Directory domain, you can use a GPO to quickly and easily configure your computers to use Automatic Updates and look to the WSUS server for those updates. But what if you are not using AD, can you still use WSUS? Yes.....

WSUS works just as well in Non-AD enviroments although the configuration is a bit more work on the client side. In order to control the behaviour of Automatic Updates and point the computers to the WSUS server there are a number of registry entries that have to be modified and/or created. To begin, open up regedit ..."


I've recently needed to start looking again at automated patching. While the machines I would be using WSUS with are members of a AD domain, I may not be able to get the settings pushed out with GPO (Think "segmented" WSUS... not silo'ed/rouge... um... yeah, "segmented" that's it... :| ).

Now I just need to find the time to install WSUS, configure, test, deploy the reg file to client pc's, train the operators and turn over operations...

(via Tiernans Comms Closet - using WSUS without Active Directory)

Thursday, October 13, 2005

"Searching encoded strings in SQL Server 2000?"

Sorting It All Out : Searching encoded strings in SQL Server 2000?

"A guy named Michael (who is not me) asked the following question in the Suggestion Box:
Is it possible to search an NVARCHAR column containing string data encoded in a number of different encoding types?

I'm dealing with iso-8859-15, big5, utf-8, iso-8859-1, us-ascii encoding types and need to search the strings for keywords using either full-text indexing or the LIKE clause.

The quick answer is no. ..."


As I am now playing in Unicode (aka non-ASCII) land I found this interesting...

Wednesday, October 12, 2005

Competition Is good... (Blogger adds Hotkey Nav)

Bloglines

"You can now navigate through Bloglines with hotkeys! You will find this legend at the bottom of each feed display page.
Hotkeys: j - next article k - previous article s - next sub f - next folder A - read all r - refresh left pane"


I love the power of competition... While Google Reader doesn't do it for me, it IS a positive influence forcing all the players in the same space to take a hard look at themselves.

It seems that Blogger first response is to add hotkey nav.

And I'm already wondering what I did without them... ;)

eBay: Classic Vintage PC Collection

eBay: Classic Vintage PC Collection (item 8706273723 end time Oct-15-05 10:00:00 PDT)

"... Includes over 430 vintage computers. From Altair to Zenith!

Includes over 40 vintage printers including early Epson, Apple, IBM models and more.

Includes Several hundred hardware items including vintage terminals, monitors, modems, acoustic couplers, mice, joysticks, accessories, S-100 computer boards and more.

Includes countless books, software, marketing brochures and accessories.

Includes set of Byte Magazines plus many duplicates. 100's more Magazines for TRS-80, Commodore, Popular Electronics, Radio Electronics, Osborne, Amiga, Texas Instruments, DEC, Sinclair, Microsystems CP/M Journal, Dr. Dobbs and more. Copy of all photos are included in the sale. Does not include the website. ...

WINNING BIDDER WILL PAY FOR ALL SHIPPING COST, HANDLING AND PACKAGING FEES! TOTAL COST WILL BE DETERMINED AT THE END OF AUCTION. APPROXIMATE WEIGHT ON THIS LOT IS 6,000 LBS. ..."


Oh I so want this... Talk about being #1 in any geek one-up-man-ship fest! Since they are pretty much local, I can rent a truck and pick it up myself! What a deal!

Now to ask my wife...

[No honey... not "THE LOOK"! Anything but "THE LOOK"... ]

Index.DAT Viewer

Index Dat Spy - index.dat file viewer!

"Index Dat Spy is a powerful and easy-to-use application that exposes the contents of any index.dat file - even if the file is currently in use by Windows. It translates a great deal of binary data - i.e. internal computer information - into a more human-readable form. And you don't have to be a programmer to read it either!

index.dat files have been the subject of much discussion since Microsoft has released relatively little information about them. Even after clearing your browser history, emptying your cache and deleting your cookies from Internet Explorer, there still remains information about where you've been surfing hidden away in these index.dat files. Although Microsoft claims that their is nothing special or secretive about these files, all versions of Windows tend to go to great lengths to obscure these files. ..."


Interesting... Not that I need to hide anything on my machine (um... yeah...) but given my current project (i.e. EDD), I find this professionally interesting.

What would be really cool is a library/COM component/assembly/API where I can extract this info for my own usage (cause I'm just too damn lazy to reinvent the wheel Steven's already invented).

Oh well, just another thing on my list of stuff to R&D (without which what fun would life be? :)

(via SHELL EXTENSION CITY)