Modern software engineering practice heavily relies on third party libraries, existing frameworks, high level programming languages, and agile development methodologies, which allows us build more complex software and deliver it faster. However, on the other hand, such practice causes some negative consequences such as bloatware and feature creep. A phenomenon of importing and implementing redundant features into software products has been observed in many software evolution and iteration lifecycles. In this paper, we describe an approach to customizing Java bytecode by applying static dataflow analysis and enhanced programming slicing technique. This approach allows developers to customize Java programs based on various users' requirements or remove unnecessary features from tangled code in legacy projects. Our preliminary evaluation and case study results show that our approach has the potential for practical use.