Rite Aid on Thursday posted mixed fourth-quarter earnings results and gave a weak forecast for the upcoming fiscal year.

Here's what the company reported compared with what Wall Street was expecting, based on a survey of analysts by Refinitiv:

Earnings per share: A loss of 1 cent, adjusted, vs. a loss of 2 cents expected

Revenue: $5.38 billion vs. $5.56 billion expected

Rite Aid's pharmacy benefit manager, EnvisionRx, signed up more Medicare Part D members, helping grow the unit's revenue to $1.46 billion, a 1.2 percent increase from the year-earlier quarter. Sales of retail goods and medications at pharmacies open for at least a year increased 0.7 percent from last year. Prescription medication sales led the growth while sales of drugstore staples like candy and paper towels declined.

On an unadjusted basis, Rite Aid reported a fiscal fourth-quarter loss of $273 million, or 26 cents per share, down from a gain of $767 million, or 73 cents per share a year earlier. When adjusted, Rite Aid lost 1 cent per share, better than the 2 cent per share loss analysts surveyed by Refinitiv expected. Net sales dropped to $5.38 billion from $5.39 billion, below expectations of $5.56 billion.

"In the fourth quarter, we continued generating critical momentum in key areas of our business while taking important steps to position Rite Aid for future growth," outgoing CEO John Standley said in a statement.

For more on investing in health-care innovation, click here to join CNBC at our Healthy Returns Summit in New York City on May 21.

For fiscal 2020, Rite Aid said it expects earnings per share to fall between a loss of a penny to a gain of 4 cents. It also projected revenue to fall between $21.5 billion and $21.9 billion. Analysts were predicting earnings of 2 cents per share and revenue of $22.09 billion. The company expects same-store sales to be flat or increase up to 1 percent.

Rite Aid sold nearly half of its stores to Walgreens Boots Alliance after regulators thwarted an outright sale of the company, leaving Rite Aid with a much smaller footprint — and a much weaker negotiating position than its larger rivals.

Shares of Rite Aid slid nearly 1.3 percent to 56 cents in premarket trading. Rite Aid's shares have lost 66 percent of their value over the past year, with the price hovering under $1 since December. The company plans a reverse stock split at a ratio of 1-for-20, effective April 22, to prevent the New York Stock Exchange from delisting its shares.

Rite Aid last month said Standley, Chief Operating Officer Kermit Crawford and Chief Financial Officer Darren Karst would all leave. The company also cut 400 full-time jobs, or 20 percent of its corporate positions. Rite Aid said the move would save $55 million a year, with about $42 million being realized in fiscal 2020.