In this study, we have derived close form of the Casimir force for the non-interacting ideal Bose gas between two slabs in harmonic-optical lattice potential by using Ketterle and van Druten approximation. We find that Bose-Einstein condensation temperature $T_{c}$ is a critical point for different physical behavior of the Casimir force. We have shown that Casimir force of confined Bose gas in the presence of the harmonic-optical potential decays with inversely proportional to $d^{5}$ when $Tleq T_{c}$. However, in the case of $T>T_{c}$, it decays exponentially depends on separation $d$ of the slabs. Additionally we have discussed temperature dependence of Casimir force and importance of the harmonic-optical lattice potential on quantum critical systems, quantum phase transition and nano-devices.