Digital Tool Factory blog - Page 10 of 34 - Backend web development in Atlanta GA Digital Tool Factory blog - Page 10 of 34 - Backend web development in Atlanta GA

The Digital Tool Factory Blog

How to fix Visual Studio slowness problems by deleting ExpansionsXML.xml

The Problem

'Program Guy 1' photo (c) 2009, Briles Takes Pictures - license: http://creativecommons.org/licenses/by/2.0/I’ve had Visual Studio 2010 installed from the first day it was released, and lately it has gotten significantly slower.   That’s not surprising with an increased number of add-ons and extensions.  However, closing the program recently started taking an increasingly long period of time.  It recently reached OVER EIGHT MINUTES so I opted to do some googling.

The Cause

I started by installing PerfMon, and PerfMonWatson, which while telling me the computer was slow, did nothing to tell me of the nature of the problem.  Then I installed Process Monitor by the Sys Intenals division of Microsoft and watched what happened when I opened adn closed the Visual Studio 2010.

The result?  When you open or close Visual Studio 2010 a terrifying number of things happen, but in my case an xml,

C:Users[UserName]AppDataLocalMicrosoftVisualStudio10.01033ExpansionsXML.xml

was being accessed, read and closed several thousand times.  Apparently Visual Studio will do that when the file gets corrupted.

The Solution

Just delete the .xml file and everything should run normally.  Visual Studio 2010 regenerated the file, and it was about one fifth the size it was before.  Everything is working slightly faster in general, and it now closes at a normal speed.


22
Jun 12


Written By Steve French

 

Which jQuery cropping plugin should you use?

'As night falls foggy on San Francisco, construction begins on @BalsaMan's moderately famous face.' photo (c) 2010, Aaron Muszalski - license: http://creativecommons.org/licenses/by/2.0/I recently had the need to do some automated image cropping.  I was already using the wonderful ImageResizing.Net plugin, which made all of the server code very easy.  It came with some sample code that uses the JCrop plugin (by Deep Liquid).

Jcrop does it’s job very well.  However…

In the modern web development environment, plugins are both a blessing and a curse.  The blessing portion is that the plugins work very well.  JCrop is no exception.  It does a great job selecting the proper portions of an image to crop in an easy and intuitive manner.  So far so good.

The curse is that every need is somewhat new to the world, and the factory settings ALMOST apply, but not quite.  I was pulling  a list of uploaded images from the server, and I wanted the images to pop up in a normal jquery ui modal dialog window.  It was trivial to display the large photos from a list of thumbnails.  So….

Now to integrate the two

I opted to have the JCrop appear after the thumbnail was clicked.  It did.  So far so good.

Then I ran into problems.  After you select one image, no matter what you select next, the first image will always show up in the modal window, which was a considerable problem.  If you disable JCrop the problem went away, but no matter what combinations I tried in terms of loading order, ready states and dailog and object creation I could not get jCrop to to work in this situation.

Mind you, this is not jCrop’s problem, but it was not the situation I was trying to use

Enter ImgAreaSelect

After quite a few hours I gave up and let my fingers do the googling for other plugins.  I was led to ImgAreaSelect – which was simple and easy to use, and did not have the problems with the dialog boxes that jCrop did.  The documentation was good too.


18
Jun 12


Written By Steve French

 

Less Accounting Review – a 10 part series – The Signup

'Accounting Sense != Common Sense' photo (c) 2007, Paul Downey - license: http://creativecommons.org/licenses/by/2.0/I recently signed up with Less Accounting and I will be publishing a Less Accounting review  and experiences with the setup process here (read the introduction).

  1. Introduction
  2. My accounting background
  3. The Signup (This post)
  4. Import Quickbooks File
  5. Wire Account
  6. Set Recurring
  7. Hook up Bank Account
  8. Hook Up American Express Account
  9. Less Accounting – One Week Later
  10. Less Accounting – One Month Later

There really isn’t much to the signup process (which is a good thing).

I’m tempted to leave it at that for this part of the review, but one thing that does bear mention is the overall look and feel of their website, and the role it plays in your decision making.  The site isn’t flashy, or terribly notable graphically, however, it is very, very well written, and designed to show off the writing, which makes it quite persuasive.

It has a good Unique Selling Proposition (see the Copy Hackers Series for more information on that) and it identifies me quickly (their novice button), and I have a clear action to take. based on those two factors.

The information presented was all useful, both to me, the end user, and my accountant (who needs to approve these sorts of things).

On the whole, it was good enough to get me to sign up and try it.  They identified my frustrations and promised me a cure with at a decent price and nominal risk.  My big concens were importing American Express data, as well as connecting to my bank without additional fees, which they put more of less on the home page.

On the whole, their signup process gets an A+.


08
Jun 12


Written By Steve French

 

How to fix “The system cannot find the path specified” error in asp.net mvc 4

The Problem:

So, you’re coding away, and you run your asp.net mvc 4 site and you get the following error: The system cannot find the path specified

The Cause:

Most likely you have not already specified the database in the web.config, it’s a simple fix.

The Solution:

Just add this code into the web.config

<add name=”BlogProphetsiteContext” connectionString=”Server=.SQLEXPRESS;Database=BlogProphetsite;Trusted_Connection=true;MultipleActiveResultSets=true” providerName=”System.Data.SqlClient” />

and all will be good. For some reason it does not automatically generate one for you.


08
Jun 12


Written By Steve French

 

Facebook AWD is the WordPress plugin to use

'facebook business' photo (c) 2010, Sean MacEntee - license: http://creativecommons.org/licenses/by/2.0/I have now retracted my previous WordPress plugin review, and I have now found FaceBook AWD plugin quite useful, and I’m giving it the full run through.  So far I like it quite a lot.  We’ll see how well it works over the long term.

There seem to be quite a number of features I’ll never use, but so far, so good.


01
Jun 12


Written By Steve French

 

Tribal maintenance goes farther with SharePress

As it turns out, the free version does not do what I thought it did. Retracted.
'sharing lunch' photo (c) 2009, Angie Muldowney - license: http://creativecommons.org/licenses/by-nd/2.0/For some reason I decided to engage more directly with my very few Facebook fans and after a bit of googling, I opted to use SharePress by Fat Panda.  Thus far, I am very impressed, and it joins the lofty list of WordPress plugins I actually use on all of my blogs AND recommend to client, an honor currently shared only by WordPress  SEO by Yoast.


31
May 12


Written By Steve French

 

How to create a Cron job with MySqlDump, and use GZip Compression

'Wordpress cron file' photo (c) 2010, Harsh Agrawal - license: http://creativecommons.org/licenses/by/2.0/Full Disclosure: I am a long-term Microsoft Windows user and developer and I haven’t used any sort of Cron job in about 12 years, so all this was new to me.

What is a Cron job?

It’s just something that runs chronically, i.e. an automated procedure on the server that runs every day or hour.

What is MySqlDump?

It’s a nice simple way to do a backup of a MySql Database

What is GZip Compression?

It is the Linux version of zipping a file, using whatever open source algorithm they use.

How do Cron Jobs, MySqlDump and GZip Compression come together?

In my case, I needed to backup a very large multisite WordPress database.  After some further discover I discovered that it would behoove me to compress the database as well.   Without compression, the backup file was 250 megs, with compression it was 25 megs.

What is the syntax for a Cron Job with MySqlDump and GZip Compression?

Just use this

mysqldump –opt -Q -u[YourUserName] -p[YourPassword] [YourDatabaseName] |  gzip >/path/to/desired/backup/location/`date`.sql.gz

That will create a file named after the current date and time that is a zipped version of your database.  It runs surprisingly quickly.

What is the catch?

The reason this particular little task took me some extra time to do is because I had forgotten that Unix system use the back tick character (`) and not the single quote (‘).  FYI – the back tick character is the one located underneath the escape key.


25
May 12


Written By Steve French

 

Less Accounting Review – Intermission Part II

It’s been a little while since my last update.  I have finally gotten all of the invoices (ten years worth) into Less Accounting.  For some reason their import procedure marked them all as drafts and did not import the invoice numbers, which pretty much made them useless and I had to go in and change ever one of them.  That took many hours.

The rest of the review is coming soon!

 

 


21
May 12


Written By Steve French

 

How I explain Paul Graham’s Maker schedule and Manager schedule without being insulting

'Day [009]  Schedule.' photo (c) 2010, Sadie Hernandez - license: http://creativecommons.org/licenses/by/2.0/One of Paul Graham’s most useful insights has been his Maker Schedule vs Manager Schedule. Go ahead and read the link if you’re not familiar with the concept.

It is

  • True
  • Useful
  • Deep
  • and very hard to explain to people without being insulting

By singleing yourself out as a “maker”, and hence on a “Maker Schedule” you run the serious risk of alienating all of your equally smart colleagues who have different interests and work responsibilities.  Coders, designers and artists will understand it immediately, but if you’re not one of those people it can sound like you’re putting yourself on a pedestal.

Remove Maker Schedule and Manager Schedule from the description

Just remove the job description, and substitute the noise that you’re making, which implies the type of work that you’re doing.

If you’re producing mouse clicks, you’re doing manager work, and you’re on a manager schedule.  If you’re producing keyboard clicks, you’re doing maker work, and you’re on a maker schedule.  The work is being labeled, not the person.  No one is categorized as “creative” or “business people”, it’s just the work you happen to be doing at the time.

I’ve found that people understand this instantly and intuitively.  No need to explain “Flow” or why interruptions cost so much time.  People can relate to the fact that (usually) work involving the keyboard just takes longer than work involving the mouse, and no one is inadvertently put down by being implicitly labeled.

That’s worked for me anyway.


18
May 12


Written By Steve French

 

How to fix problems running Windows Azure web applications locally

The Problem:

You have an asp.net mvc 3 web project, and you are running it as part of a windows azure web application.   In my case it worked initially, but after I installed some Visual Studio plugins, run Windows Update, and installed a new router, it mysteriously stopped working.  A few of the error messages had me thinking it was caused by Sql Server, but I was mistaken.

The Cause:

This stumped me for several hours, but after much trial and error I discovered that the problem was with port mapping.

In the output window, I had the following messages:

Windows Azure Tools: Warning: Remapping public port 80 to 87 to avoid conflict during emulation.
Windows Azure Tools: Warning: Remapping public port 3389 to 3390 to avoid conflict during emulation.
Windows Azure Tools: Warning: Remapping private port 80 to 89 in role ‘MyCoolSite’ to avoid conflict during emulation.
Windows Azure Tools: Warning: Remapping private port 3389 to 3390 in role ‘MyCoolSite’ to avoid conflict during emulation.

I had enabled a homegroup somewhere along the way, which changed my network location, which somehow made changes in the firewall.

The Solution

This was more blind luck, but I got a windows firewall popup that asked me if I wanted to allow the Visual Studio Process to use lo these many ports.

So, in sum, check to make sure all of your ports are open.


15
May 12


Written By Steve French

 




Copyright 2011 Digital Tool Factory. All Rights Reserved. Powered by raw technical talent. And in this case, WordPress.