Most written leases say that the landlord can take you to court immediately and without notice for failure to pay rent on time. The landlord does not have to accept late rent. If there is no written lease and you fail to pay rent, the landlord must demand the rent from you 10 days before beginning a summary ejectment action for eviction. This demand does not have to be in writing.
Until the court rules that the landlord can have possession of the premises, you can stop the eviction if you offer all of the past due rent and late charges unless you have violated some condition of the lease or rental agreement. (If there are late charges, they must be limited to $15 or 5% of the rental payment, whichever is more.) If the landlord has started a summary ejectment action, you must also offer to pay the court costs in order to stop the eviction.
Remember that stopping an eviction by offering to pay past due rent and court costs works only if there is no written lease, unless the Landlord agrees to accept late rent and costs. Get such agreements in writing.