I'm not sure I understand the problem. Are you trying to alter a JPEG image from within Adobe Illustrator? If so, Illustrator is not really the tool meant for that job. A pixel-based image editor such as Photoshop is better suited for such tasks. Illustrator's primary purpose is for creating and editing vector-based artwork.