Surface waves generated by a charged-particle bunch at the semi-infinite planar periodic wire structure are analyzed. It is supposed that the bunch moves parallel to the edge of the structure. The influence of the grid is described by the averaged boundary conditions. The analytical results are given for a general case, which takes into account the finite period and wires radius. It is shown that the surface waves excited by the bunch propagate along wires with the speed of light in vacuum. The number and the structure of these surface waves depend on relative location of the bunch path and the grid. One type of wave is always excited, but its magnitude decreases with distance from the bunch path to the structure edge. If the bunch projection falls on the half-plane occupied by wires, then additionally three surface waves are generated: two of them are equivalent to ones excited by the bunch moving along infinite wire grid and another one represents the surface wave reflected from the edge. The analysis of the surface waves shows that their structure allows for determination of the length of the bunch. Typical numerical results are presented.