We report a measurement of the amplitude ratio $r_S$ of $B^0 to D^0K^{*0}$ and $B^0 to bar{D^0}K^{*0}$ decays with a Dalitz analysis of $Dto K_S^0pi^+pi^-$ decays, for the first time using a model-independent method. We set an upper limit $r_S < 0.87$ at the 68% confidence level, using the full data sample of $772times10^6$ $Bbar{B}$ pairs collected at the $Upsilon(4S)$ resonance with the Belle detector at the KEKB $e^+e^-$ collider. This result is obtained from observables $x_- = +0.4 ^{+1.0 +0.0}_{-0.6 -0.1} pm0.0$, $y_- = -0.6 ^{+0.8 +0.1}_{-1.0 -0.0} pm0.1$, $x_+ = +0.1 ^{+0.7 +0.0}_{-0.4 -0.1} pm0.1$ and $y_+ = +0.3 ^{+0.5 +0.0}_{-0.8 -0.1} pm0.1$, where $x_pm = r_S cos(delta_S pm phi_3)$, $y_pm = r_S sin(delta_S pm phi_3)$ and $phi_3~(delta_S)$ is the weak (strong) phase difference between $B^0 to D^0K^{*0}$ and $B^0 to bar{D^0}K^{*0}$.