A non-transitory computer-readable medium storing an embroidery data generating program, the embroidery data generating program comprising instructions, when executed, to cause a computer to perform the steps of:
- acquiring pattern data representing a pattern that is a target to generate embroidery data;
- identifying a base area that is an area in which a plurality of base stitches are to be formed, the plurality of base stitches including a plurality of intersecting portions, each of which is a portion at which two base stitches of the plurality of base stitches intersect, the two base stitches extending in directions different from each other;
- generating first sewing data to be used to sew the plurality of base stitches in the base area;
- acquiring second sewing data to be used to sew the pattern represented by the pattern data in an area that includes at least a part of the base area;
- and
- generating embroidery data which includes the first sewing data and the second sewing data, and in which a sewing order of the first sewing data is set to be in advance of a sewing order of the second sewing data.