Although this question may look like it belongs in the realm of religion, it is actually asking about the mechanics of trading on the stock / options / Forex markets.
Some background information:
Questions and answers about gambling on the Christianity.SE show that members of some denominations do not gamble because of reasons such as that it encourages receiving something for nothing and taking someone's money in exchange for nothing (which seems to refer to the other players who do not win).
Of course it could be argued that the price of a lottery ticket is not exactly "nothing" (it is still something) but I am more interested in the concept of receiving another persons money in exchange for nothing.
To frame this into the stock / options markets or Forex markets, it would be akin an investor gaining at the direct expense of other investors (who may have invested differently).
[Update]
There is for example this quote in the book "Mastering the Trade: Proven Techniques for Profiting from Intraday and Swing Trading Setups". The author John F Carter writes (ch. 1, par. 1):
Funds need days, and sometimes weeks or months, to move into and out of sizable positions without showing their hand. If they do show their hand, then other funds will front-run them (jump in front of their orders) and bury them if possible. That is how money is made in the markets - by taking it from other traders. If you think this sounds ruthless, you are right. It is.
Also when it comes to trading on the Forex it looks like the trading does not really contribute to anything. It could contribute in the sense that a sufficiently sizable investment might e.g. increase the value of a national currency, but this could also be detrimental for the nations exporting companies (unless they have hedged positions). On another hand it looks like betting against a currency (to make it lose value) can be a source of profit(?)
[End of update]
The question I wanted to ask is:
Can the mechanics on the stock / options / Forex markets in some situations be such that an investor profits at the direct expense of other investors?