Reflexive, direct object and indirect object pronoun, must be attached to an affirmative command. In all cases, with affirmative commands, the object pronouns are attached to the imperative form of the verb. One way to remember the order is with the accronym: RID that stands for Reflexive+ Indirect+Direct object pronoun.
Compre ud. El carro.
If both direct and indirect object pronouns are attached, for example when you write “lo,” or “la” at the end of a word, the indirect object pronoun comes before the direct object pronoun. To emphasize a direct command in Spanish, we add “lo”; “la”; or emos; melo; at the end of the word.
Cómpremelo ud. Buy it from me
When you write a command with a two pronoun, an accent is used to emphasize the force of the verb.
Command: haz (one syllable)
hazlo (one pronoun, no accent required)
házmelo (two pronouns, accent is required)
When writing a negative command, the object pronoun goes before the imperative form of the verb.
No venda usted el carro - Do not sale the car.
No lo venda - Do not sale it.
One way to remember how to write commands with pronouns is to follow this rule: if one of the pronouns starts with the letter “l,” you change the “l,” for “se.” This applies when you see the pronouns: lo; los, la, le, les.
le lo = se lo Gladys se las regaló a ella. (thrid person)
le los = se los Julio te las dió a ti (second person)
le las = se las Laura me las compró a mi ( first person)
les la = se Ernesto se los vendió a ellos.
les los = se los
les las = se las Les los = se los