Another method or way to not close indexes during Restore

Please do not open multiple threads on the same question. This has already been answered here.