Archive page for custom post type not working

I found a solution here:
http://gabrieleromanato.name/wordpress-fix-the-404-error-on-custom-post-types/

Here’s what you need to do to get it to work (quoted from site above):

  1. Go to Settings → Permalinks and change your current structure to:
    /%category%/%postname%
  2. Save changes.
  3. Restore your original permalink settings. Save changes.