The book of Ecclesiastes has many layers. It describes the lives of people under the sun who are cut off from God. To that extent, life is vain and a grasping for the wind. In addition, when Solomon addresses the reader DIRECTLY, he is not talking about people who have turned away from God and who refuse to submit to God. It is important to see the distinction.