Monday, February 20, 2012

Menustrip disapears in Visual Basic

Fiddling with the resources in a project with a menustrip seems to cause the designer to re-write the XXX.Designer.vb file and drop some key lines from Menustrips ( I have also found references to toolstrip and status strips doing the same thing Here  and  Here and Here .

The problem is that the designer drops the lines that add the menustrip to the form and the sub-items to the menu strip.  I have hand corrected this... but it seems to recur.  (I'm using VS2010 at the moment but the above comments go back to VS2005... so it could be some shared code between the versions)

So on friday the missing line was

Me.TheMenuStrip.Items.AddRange({Me.FileToolStripMenuItem,....blah blah more top level items here})

Now I have lost the above line as well as all the lines on the drop down menus.  So the whole hierarchy has to be rebuilt by hand.

For example

 Me.FileToolStripMenuItem.DropDownItems.AddRange({Me.NewToolStripMenuItem, Me.LoadToolStripMenuItem, ... blah blah more drop down items})

My guess is that the designer will trash all my work at some point in the near future... so I need to find a fix.  Either completely re-create all this and hope it sticks,  turn the designer off or hand code the whole menu structure in a file outside the designers control ... other???

Yet another Pain Point that I don't need.

Monday, February 6, 2012

The new computer blues.... part 389

Still working on transcoding my life from my old machine to the new box.  I have finished trying to move software licenses across.  The final casualty list is:

Profactor Include Manager
Parasoft Insure++
Visual Lint
Camtasia Studio

I think these are the only ones I have completely lost... Adobe CS4 Master Collection is on life support but seems to be functional. 

I have put the old hard drive into a caddy I scrounged and mounted it permanently in the new case rather than the external io board that I have been using to swap it back and forth between the old and the new case.  I have deleted all the duplicate backups between the two systems and apart from deleting the system partition... I think I have stabalised the file pile. 

I have killed the virtual machines I created of the old system as they simply did not boot no matter how tricky I tried to be.  I could mount one of them as a VHD... but only enough so I could create a WIM file from the volume.  Since the WIM is 42GIG rather than the 92GIG for the VHD, I'm keeping that for a while longer. I've already tested that I can rebuild the system partition and boot from the WIM on bare metal... but not as a virtual machine.. doh. It would have been nice to have that option... but the reasons and the effort are just not making it a worthy investment of my time anymore.

I have put the old case back together, tagged it and put it into the scrap pile... slightly melancholy moment.... more about the amount of time I have spent with it rather than its current state of sluggish cpu, dying hard drive and dust bunny collection.  Still its been my partner in crime for nearly half a decade and rarely missed a beat. 

Just have to get a robust backup solution implemented now and I am back to making forward progress.  I find it quite scary to collapse from 3 copies of everything, to two... to idea of deleting my old backups to make room for the new (the drive is too small for both) is quite nerve wracking.  I have only just finished a data recovery job on another machine that has takes about two months.  Going commando with my my last 10 years of data is just a little.... worrying.  Even if it only takes a few hours to rebuild the backup.  Probably should just bite the bullet and buy a bigger backup drive... half a T is just not enough anymore.

Another collection of Exception handling wisdom

Friday, February 3, 2012

Org psychology at Universities

Within a corporate organisation, you have individuals and the organisation as an entity.

The individuals are working both, for themsevles and to further the goals of the entity(we assume).

This is a nice simple picture... but what if there is resource competition within the organisation?  Say inter-department competition for resources? Is it just an inverse hierarchy? Simply an us and them fight only differentiated depending on the level at which the competition occurs?

Ok, fairly simple so far....

Now what happens if the managment is cash-cowing one department to expand or push resources into another? 

At the indivudual level.... probably not a huge change. (0)
At the department level... one is asked to altruistically "take one for the team".  (-1)
At the organisation level.... progress. (+1)

Now what if the organisation is a University where staff not only have loyalty to themselves, their department and their University... but also to their field and professional organisations. 

Suddenly taking one for the team means that their department, field and professional organisations are robbed while resources are sent elsewhere.  Research they are passionate about and think is significant is stalled or blocked while someone else eats the cake.  Keep in mind that a researcher who is not researching... is effectivly wasting their life.

So, seeing resources moved elsewhere for "organisational purposes" results in something like this

At the individual level .... probably no change (0)
At the department level .... a loss (-1)
At the organisation level ..... a win (+1)
At the field level .... a loss (-1)
At the research level ... a loss (-1)

Universities are more like charaties that support people... as soon as one stops paying... the people need to move to another.  There is no point sitting and marking time.  Time is the most precious resource.

Wednesday, February 1, 2012

Adobe Photoshop CS4 has stopped working

"Adobe Photoshop CS4 has stopped working"

What a  fun and useless error message.  I've just finished installing CS4 Master collection on Win 7 64bit and photoshop is DOA. I have tracked the problem to a bad plug-in.

C:\Program Files (x86)\Adobe\Adobe Photoshop CS4\Plug-ins\Extensions\ScriptingSupport.8li.

I simply removed that plug-in from the directory (after much experimenting) and tada! working photoshop. Now to look for updates.


"Adobe has detected that the application Adobe Illustrator CS4 has unexpectedly quit." with a little popup about ScriptingSupport.aip.

Remove that plug-in and restart....

Now its "ScriptsMenu.aip" and "Services.aip" that its having trouble with but the program seems to be mostly functional.   Remove them aswell.

Now Illustrator loads without errors... stranger.


"Adobe InDesign CS4 has stopped working".... pattern anyone?

Tried moving various bits from InDesign and I can't isolate the problem.

Moving on....

Acrobat works fine.

"After Effects error: Crash occured while invoking plug-in "Scripting"."  Tada!

If I remove the "Scripting.AEX"... After Effects loads and works. 

Contribute is still choaking on a missing serial number.... fix that later.

Bridge is playing dead.

Device Central seems fine.

"Adobe had detected that the application Adobe Encore has unexpectedly quit.".... really??? Ya think?
No obvious error messages and removing the plug-in's does not help... will try more later.

Extension Manager works.

Fireworks CS4 seems good.

Flash CS4 works fine.

Media Encoder CS4 seems fine.

On Location CS4 seems fine.

Premier Pro CS4 seems fine.

Soundbooth is choaking on a missing serial number. Fix that later.

Pixel Bender and Reader seem fine.

What a mess....

The next day

Run a whole bunch of updates via the auto updater. Just about everything seems to have received an update. ...

Acrobat 9.5.0 - Working
After Effects 9.0.3 - Crash while invoking plug-in 'Scripting".  A few more messages then the final creash report dialog.
Bridge ??? - ???
Contribute 5.0 - Working bar serial number
Device Central 2.0  - Working
Dreamweaver 10.0 build 4117 - Seems fine
Encore  -  Crash straight to crash report dialog.
Extension Manager - Seems fine.
Fireworks - Seems fine.
Flash 10.0.2 - Seems fine.
Illustrator 14.0.0 - Loaded Fine (But useless as its missing tool panels) until I added the scripting plugin's back.  Then crash to crash report dialog.
InDesign 6.0.6 - ...has stopped working. Not even a crash report dialog....
Media Encoder - Seems Fine.
OnLocation - Seems Fine
Photoshop 11.0.2 - Broken again. Not even a crash report dialog.
Premier Pro 4.2.1 - Seems Fine.
SoundBooth 2.0.1 - (No serial still ) Seems fine.
Reader 10 - Seems fine.

Check for More Updates....
Says there were 6 updates pending...

Extension manager, Some common updates, Photoshop camera raw, Device central, Version Cue server... must have been something else I missed. 
Not much of use it would seem...

After Effects 9.0.3  - still crashes when invoking "Scripting" plugin.
Encore - Still crashes completely.
Illustrator - (With the scripting plugins still added ) still crashes. So I have removed them and it seems stable.
InDesign - still crashes to death.
Photoshop - Still crashes to death. (However if I remove the ScriptingSupport.8li plugin ... it works!)

I can live without AfterEffects, Encore and InDesign... but I would rather get what has been paid for...

Indepth fiddling

Indesign is loading all the pluging successfully but is crashing at "Initialising Panels".  Which seems to be where it start trying to "Use" the plug-ins.  So perhaps the coders for InDesign have just delayed the Initialisation step away from the load step... unlike the other dev teams.  Same crash problem just delayed in the setup.  My thesis is still that its a bad plugin.

Nope... remove all plugins and it still crashes at "Starting up Panels".... damit.

Pull out Process Monitor...

The last issue before it choaks to death is InDesign tries to create a file in a write protected directory.
"C:\Program Files (x86)\Adobe\Adobe InDesign CS4\ExtendScriptResources\extendscript-en_GB.dat"

The file does not exist and the directory is write protected....

Remove the write protection.... what do you know... I can't.... after trying much stupidity... I copied another of the data files ( the en_US.dat) and renamed it and it now is not failing in ProcMon. (This missing file is probably a bug for Adobe to fix but it does not seem like its the cause of this crash.

The final line in ProcMon before the thread exits is querying a Quicktime file QuickTime.qts which works.... interestingly when I filter for quicktime in the path, there is a missing dll called QuickTimeGlue.dll. It should be in the InDesign directory.??? Not sure if this is significant. Quick copy and paste from one of the other Adobe products and.... still dead on arrival.

Incompatable with DisplayFusion?   Nope.

Lots of Buffer Overflows reported.  Seems to be making a mess looking at some security files....
Couple of Buffer Too Small's... nasty.

All manner of issues in the ProcMon trace but mostly its just noise... nothing obvious to track down.  Just evidence of lazy programming.

Dead end?

Time to crack open the debugger....  crash is happening in ntdll.dll which is a system file. 

Im getting an unhandled exception at 0x773415de in ntdll.dll.  Its just incrementing a register by 4. Probably walking a data structure or overflowing a buffer....

Ok, after a very long pile of Unhandled exceptions..... I got bored.  This is a mess that I just cannot gracefully fix. 

On to other problems.