When trying to insert a subform on a form, you may receive the error "Invalid or Nonexistent Document". At first I thought I had reached some arbitrary limit on the number of subforms but I only had 4. The one thing I did notice is that I also had an embedded view.
After removing the view, the insert subform worked. I examined the view and realized that I was computing the name of the view to display. If I explicitely specified a valid Notes view name (ie: ($All)), everything worked well. I concluded that for some reason Designer wants to know the view name after inserting a certian number of subforms. Since this is a Web only form, I decided to change the formula to explicitly name of valid view for the Notes client and leave the formula untouched for the Web.
Here is a simplified version: @If(@ClientType="Notes";"($All)";"F_" + @If(MyVar="REGIONS"; "COUNTRY_REGIONS"; "ALL_REGIONS)) Hopefully this will save you some time in debugging.