No, applying for shares in an IPO or actually bidding for shares in an IPO doesn't give any guarantee to get the shares.

 As it's a bidding process, allotment depends on the number of bids received in different categories, the price at which the investor applied for shares etc.

Once the IPO closes, the registrar of the issue collects all the bidding information and prepares a ‘Basis of Allotment'. This document provides information about the bids received by a variety of investors at different prices and the pattern of allotment.