In 1981, β Pictoris showed strong and rapid photometric variations possibly due to a transiting giant planet. Later, a planetary mass companion to the star, β Pic b, was identified using imagery. Observations at different epochs (2003 and 2009-2015) detected the planet at a projected distance of 6 to 9AU from the star and showed that the planet is on an edge-on orbit. The observed motion is consistent with an inferior conjunction in 1981, and β Pic b can be the transiting planet proposed to explain the photometric event observed at that time. Assuming that the 1981 event is related to the transit or the inferior conjunction of β Pic b on an edge-on orbit, we search for the planetary orbit in agreement with all the measurements of the planet position published so far. We find two different orbits that are compatible with all these constraints: (i) an orbit with a period of 17.97±0.08-years along with an eccentricity of around 0.12 and (ii) an orbit with a period of 36.38±0.13-years and a larger eccentricity of about 0.32. In the near future, new imaging observations should allow us to discriminate between these two different orbits. We also estimate the possible dates for the next transits, which could take place as early as 2017 or 2018, even for a long-period orbit.