I think I wrote this somewhere before but the biggest thing you can do to get people away from you at work is be a megasuper-concentrated ball of BAD BAD body language.
Not only do you give disinterested, mono-syllabic grunts (if that!), but wear the headphones even if you're not listening to anything, put your back to the entrance of your office or cube, put things in the walkway of your office or cube (as much as building safety codes will allow) that will block the entrance. I have two bankers boxes and a rolling file cabinet creating a fourth wall in my cube. Also if you don't mind having stacks of paper all over your work space that creates less room for people to just come in and makes professional business brief because there's no space. That also gives the appearance that you're messy and disorganized so use with caution because it may give off an impression of you that you don't want to have. If you're in an office, keep your door closed or semi-closed. Basically do the opposite of feng shui to your work space. If you really want to drive home the point, have BO and eat really pungent food at your desk.
As far as your facial expressions are concerned always have your brow furrowed like you're hard at work, grunt at people, never look up away from your computer, never turn around to speak to anyone that comes in your cube, look annoyed when people come to speak to you, and act like you're overwhelmed with work. One way to keep people AWAY from your cube is to promptly respond to emails. Most people won't even get up to walk across the hallway to speak to a coworker, so use email proactively. Also make interoffice mail your friend and you may have to do more phone conversations if you want people away.
Conversely, if you want people in your space you have to make the space more inviting. I used to keep beads on my cube for people to play with although I don't decorate my cube or anything. Many people put their interests, hobbies, and pics of family and friends on display for comment. Keep candy or some other food enticement in your office. Arrange furniture in a pleasing manner that invites people in. Make your space smell good, have funny and interesting cartoons on your walls. One of my coworkers had a Pimp Your Cube set that she used and it was fun.
That's generally what you can do to keep people away. For a specific person, you can be more naturally repellent in those special little ways you know them. For example, one of my old coworkers if we ever started talking sex or body issues, she'd run away. When we didn't want her around we'd just start singing penis over and over again. We wouldn't even be talking about sex before she came around but we'd do it to get her away. We once started talking about
Santorum smoothies and pink socks and she literally ran out of the office with her ears covered, screaming "I don't want to hear this!" Good times! Immature perhaps, but it worked. Another one of my coworkers has specific political issues that if you seem like you're questioning her or disagreeing with her in any way, she'll get huffy and storm out. She'll be mad at you for a couple of weeks then come back around and so it begins again.
This isn't aimed at you Tiltyred (and I read that you've found a resolution
) but I'm starting to wonder about the "Be Direct" thing. I personally prefer being direct and like just saying, "Hey, I'm kinda working on an important project that I need to get done. We'll catch up later, OK?" I can do that most of the time. I'm an extrovert and generally don't mind being interrupted. I'm also a cube-hopper myself and this makes me slightly
(but not
enough to stop, lol). I've built up enough positive social cache where I can frankly say and do mostly what I want and people respond to me well because I'm good for it. If I say "I'm busy, can we shoot the shit later?" I'll actually do it and it wasn't just words to get someone off my back.
In the two situations above I suppose my friend and I could've just said to these women, "We find your existence offensive and would prefer if you didn't come near us," or "We don't want to hang out with you," but IME so far that rarely goes over well. In less extreme examples like, "I'd prefer not to be disturbed right now for non work-related matters," you'll get the person who is a mature adult about it and doesn't take it personally, but then you're just as likely to get the person who completely takes it personally and makes it as if you don't like them and all the dramatic fallout from that.
What conclusions I"ve reached with the people above is we did things that made
them not want to come around
us, because they found us offensive, vulgar, and rude. We made ourselves distasteful and onerous to them, rather than making our negative opinions of them explicit. If I dislike someone and there's no hope of salvaging the relationship, I'd rather make situations in which they don't like me because the burden of me not liking them is lifted from me. I hope this makes sense...it's more like we mutually dislike each other and will equally take on the responsibility of avoiding each other, rather than me not liking them and doing all the work. Work smarter, not harder I say.