Motivating people to contribute knowledge has become an important research topic and a major challenge for organizations in the Knowledge Economy. In order to promote knowledge-sharing, managers need to understand the mechanism that drives individuals to contribute their valuable knowledge. Several theories have been applied to study the knowledge-sharing behavior, including social exchange, social capital, social cognitive, expectancy theories, and theory of reasoned action/theory of planned behavior (TRA/TPB). In this study, we use the social exchange theory as our base to develop a model that includes personal traits and task characteristics. We conduct a meta-analysis to see how different factors in the social exchange theory affect knowledge-sharing behavior and then use the trait activation theory to explore the moderating effect of personality trait and task characteristics. The theoretical model will be empirically tested using data collected from the members of a virtual community and employees of companies. We expect to find more insight into how the social exchange theory can be applied to explain the knowledge-sharing behavior in an organization.