I recieve an error
which error?? there are thousands of different ones


I'm guessing that it's a type mismatch, so try this:

MSFlexReview.TopRow = CInt(txtPalletID)