How do you give 30 day notice for buy or going up for sale?

Not sure why this would be a landlord/tenant issue, since the landlord can sell to anyone he or she wants and the tenant simply continues paying rent, but to a different landlord. The only "notice" required would be when the new landlord wants the rent sent to a different place or wants to change the terms of the tenancy (usually with 30 days prior notice, unless otherwise specified in a lease).