Fixing some failed uses of preview or view document API.
Merge pull request #209 from SilverYoCha/feature-3817

Fixing some failed uses of preview or view document API.