Sample codes for creating a simple progress bar