How to SaveAs the MSword file into xml file format using Java APIS?

Hello all,
I want to convert MSword file into Xml format using java APIS or any other inbuilt APIS that i can integrate in Java code.

Sorry, that doesn't make much sense.
The XML you gave is a configuration file for txt2xml utility. It doesn't represent the output format.
Are you a user of this utility?

Similar Messages

  • Help needed  while exporting crystal reports to HTML file format using java

    Help needed  while exporting crystal reports to HTML file format using java api(not using crystalviewer).i want to download the
    html file of the report
    thanks

    the ReportExportFormat class does not have HTML format, it has got to be XML. Export to HTML is available from CR Designer only.
    Edited by: Aasavari Bhave on Jan 24, 2012 11:37 AM

  • How to save the form data into adobe db?

    Hi All,
    How to save the form data into adobe db?
    I have designed one xdp file.
    Through processFormSubmission(), I got the submitted form data as Document obj.
    Then I have called the workflow kickoff program.
    code:
    InvocationRequest request = myFactory.createInvocationRequest ("myprocessname", //Specify the long-lived process name
    "invoke", //Specify the operation name
    params, //Specify input values (HashMap obj)
    false); //Create an asynchronous request
    It successfulyy started the workflow, but the submitted form data is not saved anywhere.
    And also, How get the form data from tables?
    Please provide the solution for the above.
    Thanks in advance.
    Regards,
    Saravanan G

    You need to create a process variable of type IN if you want to be able to pass data to your process. Then the params parameter (HashMap) contains a list of all the IN variables with their content that you want to pass to your process. They key is the name of the variable and the value the content. That way you should get it in your process.
    Now LiveCycle will create a column in the database for every process variable, so the content will be saved in the database just by creating that process variable.
    Jasmin

  • How to save the report file in network drive

    Hi experts,
    Can any one of you pls tell me how can  save the report file in network drive.
    My requirement:
    by running a report i wll get daily data into a list.SO, i want to keep this in a common drive (network drive:Z) where every one can acces the txt file.
    I want the code in SAP to design this.
    Awaiting for an early reply.

    Is the Z drive in the application or presentation server ?
    make sure the server has write access to the required folder
    for presentation server
    CALL FUNCTION 'GUI_DOWNLOAD'
      EXPORTING
        filename              = 'c:\test_xls.xls'
        filetype              = 'ASC'
        write_field_separator = 'X'
      TABLES
        data_tab              = itab.
    for the application server, use
    data: outfile(120).
      OPEN DATASET outfile FOR APPENDING IN TEXT MODE ENCODING DEFAULT.

  • How  to  copy  the  table1selected  records into table 2 in webdynpro java.

    Hi 
           how  to  copy  the  table1selected  records into table 2 in webdynpro java.
    venkat
    Edited by: venkatpvr on Sep 23, 2011 11:53 AM

    Hi Venkat,
    You have 2 Value Nodes one for Table1 and second for Table2.
    Table1 node having one more Value Attribute i.e check Box data type is Boolean. Now you are requirement are select records from Table1 Node and click on One Method that records will moves to Second Table2 Node.
    Create One Method for getting the Records from 1-Table to 2-Table
    CopytoTable2 ()
    In this method you have to write code like this
    If (wdContext.nodeTable1.Checkbox(true))
    If(1. Check the Table1 Value Node Size()>0)
    Get the Table1 records and set to table2 Value node.
    Else
    Please select check box// Error message
    Hope this helps!!
    Regards
    Vijay K

  • How to save the pdf file or word doc into sap table

    Hi Expertu2019s
       I have a pfd file in my presentation server .Now I want to save the pdf file into sap table using module pool program. Whenever i need, I want to open that file from the table and show it in the Screen. Please any one tell me how I can save the file. What is the table name, guide me.
    Regards,
    S.Nehru.

    Hi,
    Try the following code
    FORM gui_upload.
      DATA: lv_filetype(10) TYPE c,
            lv_gui_sep TYPE c,
            lv_file_name TYPE string.
      lv_filetype = 'PDF'.
      lv_file_name = <name of ur file>.
    DATA: tb_file_data TYPE TABLE OF text4096.
    * FM call to upload file
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename                = lv_file_name
          filetype                = lv_filetype
          has_field_separator     = lv_gui_sep
        TABLES
          data_tab                = tb_file_data
        EXCEPTIONS
          file_open_error         = 1
          file_read_error         = 2
          no_batch                = 3
          gui_refuse_filetransfer = 4
          invalid_type            = 5
          no_authority            = 6
          unknown_error           = 7
          bad_data_format         = 8
          header_not_allowed      = 9
          separator_not_allowed   = 10
          header_too_long         = 11
          unknown_dp_error        = 12
          access_denied           = 13
          dp_out_of_memory        = 14
          disk_full               = 15
          dp_timeout              = 16
          OTHERS                  = 17.
      IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    "gui_upload
    I dont think you can save the data into sap tables in PDF format.
    With the above code you can save data into an internal table.
    Regards,
    Manish

  • How to save the CorelDraw file as Tiff.

    I am new to CorelDraw. How to open the CorelDraw file in CorelDraw and save it as Tiff format using Visual Basic. Kindly help me with examples.
    Thanks,
    Prabudass

    Sorry but this is a Photoshop forum nothing to do with CoralDraw.
    You could try here. http://coreldraw.com/forums/

  • How to save the tree hierarchy into an excel

    Is there any untility avaliable in Application express to save the tree hierarchy into an excel, when shown in a page.

    Using this example, you may export any query:
    http://spendolini.blogspot.com/2006/04/custom-export-to-csv.html
    Denes Kubicek

  • How to get the update file without using Nokia Sof...

    The network connection is unreliable and downloading the firmware update using PC Suite for my Nokia E90 proves difficult. Does anyone know how I can get the firmware version 300.34.84?
    The trouble is Nokia's Software Updater does not accommodate any slight interruption to the connection during the update process. I will update this discussion with what version of PC Suite I have once I get that info.
    Any help is kindly appreciated

    In fact, it is not Possible to get the update file without using Nokia Software Updater or you should search the net to find the update files in another place and even you get them, you can not use them with NSU.
    You can Update your Device with:
    1 - NSU (Nokia Software Update)
    2 - FOTA (Firmware Over The Air) for FP2 devices ONLY.
    3 - Nokia Care Center
    there is not other way to upgrade.
    Hope useful for u.
    regards
    Nokia N79 4GB
    SW Version: 32.001 RM-348 MEA

  • How to delete the data loaded into MySQL target table using Scripts

    Hi Experts
    I created a Job with a validation transformation. If the Validation was failed the data passed the validation will be loaded into Pass table and the data failed will be loaded into failed table.
    My requirement was if the data was loaded into Failed database table then i have to delete the data loaded into the Passed table using Script.
    But in the script i have written the code as
    sql('database','delete from <tablename>');
    but as it is an SQL Query execution it is rising exception for the query.
    How can i delete the data loaded into MySQL Target table using scripts.
    Please guide me for this error
    Thanks in Advance
    PrasannaKumar

    Hi Dirk Venken
    I got the Solution, the mistake i did was the query is not correct regarding MySQL.
    sql('MySQL', 'truncate world.customer_salesfact_details')
    error query
    sql('MySQL', 'delete table world.customer_salesfact_details')
    Thanks for your concern
    PrasannaKumar

  • Req. Sample code for the Updation of Master record in MDM using Java API..

    Hi All,
    Can anyone provide me the same code for Updation of master record in MDM using Java API ??

    Hi SakthiNarayananD,
    You can additionally go through the following links to work with MDM and Java API:
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/2d18d355-0601-0010-fdbb-d8b143420f49  (Java API)
    http://help.sap.com/javadocs/MDM/SP05/(Java api programs)
    https://help.sap.com/javadocs/MDM/current/index.html  (java api codes)
    http://help.sap.com/javadocs/MDM/SP06P2/index.html (Java Docs for SP06)
    Reg: Using JAVA API - Search
    Re: Retrieving Drop Down List Value using JAVA API - Lookup values
    How to retreive records from Lookuptable of type flat - Lookup Values
    Reg: MDM with webdynpro - READ,INSERT,MODIFY
    Hope It Helped
    Thanks & Regards
    Simona Pinto

  • How to save a video file which uses the setCodecChain method on its video t

    hi! i really need your help please. i got the Code for RotationEffect and i would like to know how to save it to a file instead of playing it simultaneously in a player:
    Here is the code: Plz Help me!!! am doing my final year project
    import java.awt.*;
    import java.awt.event.*;
    import javax.media.*;
    import javax.media.control.TrackControl;
    import javax.media.Format;
    import javax.media.format.*;
    * Sample program to test the RotationEffect.
    public class TestEffect extends Frame implements ControllerListener {
    Processor p;
    Object waitSync = new Object();
    boolean stateTransitionOK = true;
    public TestEffect() {
         super("Test RotationEffect");
    * Given a media locator, create a processor and use that processor
    * as a player to playback the media.
    * During the processor's Configured state, the RotationEffect is
    * inserted into the video track.
    * Much of the code is just standard code to present media in JMF.
    public boolean open(MediaLocator ml) {
         try {
         p = Manager.createProcessor(ml);
         } catch (Exception e) {
         System.err.println("Failed to create a processor from the given url: " + e);
         return false;
         p.addControllerListener(this);
         // Put the Processor into configured state.
         p.configure();
         if (!waitForState(p.Configured)) {
         System.err.println("Failed to configure the processor.");
         return false;
         // So I can use it as a player.
         p.setContentDescriptor(null);
         // Obtain the track controls.
         TrackControl tc[] = p.getTrackControls();
         if (tc == null) {
         System.err.println("Failed to obtain track controls from the processor.");
         return false;
         // Search for the track control for the video track.
         TrackControl videoTrack = null;
         for (int i = 0; i < tc.length; i++) {
         if (tc.getFormat() instanceof VideoFormat) {
              videoTrack = tc[i];
              break;
         if (videoTrack == null) {
         System.err.println("The input media does not contain a video track.");
         return false;
         System.err.println("Video format: " + videoTrack.getFormat());
         // Instantiate and set the frame access codec to the data flow path.
         try {
         Codec codec[] = { new RotationEffect() };
         videoTrack.setCodecChain(codec);
         } catch (UnsupportedPlugInException e) {
         System.err.println("The processor does not support effects.");
         // Realize the processor.
         p.prefetch();
         if (!waitForState(p.Prefetched)) {
         System.err.println("Failed to realize the processor.");
         return false;
         // Display the visual & control component if there's one.
         setLayout(new BorderLayout());
         Component cc;
         Component vc;
         if ((vc = p.getVisualComponent()) != null) {
         add("Center", vc);
         if ((cc = p.getControlPanelComponent()) != null) {
         add("South", cc);
         // Start the processor.
         p.start();
         setVisible(true);
         addWindowListener(new WindowAdapter() {
         public void windowClosing(WindowEvent we) {
              p.close();
              System.exit(0);
         return true;
    public void addNotify() {
         super.addNotify();
         pack();
    * Block until the processor has transitioned to the given state.
    * Return false if the transition failed.
    boolean waitForState(int state) {
         synchronized (waitSync) {
         try {
              while (p.getState() != state && stateTransitionOK)
              waitSync.wait();
         } catch (Exception e) {}
         return stateTransitionOK;
    * Controller Listener.
    public void controllerUpdate(ControllerEvent evt) {
         if (evt instanceof ConfigureCompleteEvent ||
         evt instanceof RealizeCompleteEvent ||
         evt instanceof PrefetchCompleteEvent) {
         synchronized (waitSync) {
              stateTransitionOK = true;
              waitSync.notifyAll();
         } else if (evt instanceof ResourceUnavailableEvent) {
         synchronized (waitSync) {
              stateTransitionOK = false;
              waitSync.notifyAll();
         } else if (evt instanceof EndOfMediaEvent) {
         p.close();
         System.exit(0);
    * Main program
    public static void main(String [] args) {
         if (args.length == 0) {
         prUsage();
         System.exit(0);
         String url = args[0];
         if (url.indexOf(":") < 0) {
         prUsage();
         System.exit(0);
         MediaLocator ml;
         if ((ml = new MediaLocator(url)) == null) {
         System.err.println("Cannot build media locator from: " + url);
         System.exit(0);
         TestEffect fa = new TestEffect();
         if (!fa.open(ml))
         System.exit(0);
    static void prUsage() {
         System.err.println("Usage: java TestEffect <url>");

    Can you please send me Your codec class and guide me the way you use it .. i am trying to apply some filters on the movie before presenting. Any help would be appreciated.

  • How to save the client file to DB?

    I use ENCTYPE="multipart/form-data" in the html,post the file binary stream to my servlet,but I don't know how to get the file binary stream and save them to the DB :
    The html:
    <form name="frmMain" method="POST" ENCTYPE="multipart/form-data" action="servlet/myservlet">
    <input type="file" name="fileName" size=35>
    <input type="submit" value="submit" >
    </form>
    The servlet included:
    String sql="insert into test(id,photo) values(?,?)";
    PreparedStatement ps=conn.prepareStatement(sql);
    ps.setInt(1,getNextId());
    ps.setBinaryStream(2,in,in.available()); //"in" is InputStream
    ps.executeUpdate();
    ps.close() ;
    how to get InputStream?how to write my servlet ?
    Thank for any help!
    Thanks in advance!

    Well, I'm not sure to have understood what you want to do, but you can get the inputStream of the client with HttpServletRequest.getInputStream() (for example in the doPost() method of your servlet).
    Just be careful that, in this way, you will retrieve the whole HTTP stream, including headers and multipart separators. You should parse this stream if you want to get only the binary stream of the file posted...
    Well, in fact you just have to implement/obtain a basic upload servlet...
    Hope it helps...

  • HOW TO SAVE THE FLAT FILE.

    Hi Exports,
         Flat file comes to our Internal table.then i build our logic.After that i wann to save this flat file is some location(may be in presentation/ application server).that to file name along with date,time and location.agin i run the pgm and save same location and file name is also same.
    here iam giving file format.
    emp no               file name        location.
    1                          XXX               h:\kkk.txt
    2
    3
    4
    5
    again i am running same pgm
    emp no               file name        location.
    6                           XXX               h:\kkk.txt
    7
    8
    9
    10
    file name and location same but diff emp no.
    Regards,
    Krishna.

    Hi Krishna Kumar,
    if u wnat to download in to presentation server..
    then use GUI_DOWNLOAD.
    if u want to save in application server (in AL11) then u need to use
    open data set...
      DATA : dl_string(250).           " String
    *--Open data set
        OPEN DATASET dg_filename FOR INPUT IN TEXT MODE ENCODING DEFAULT.
        IF sy-subrc <> 0.
          dg_subrc = sy-subrc.
        ELSE.
    *--Transfer data
          DO.
            READ DATASET dg_filename INTO dl_string.
            IF sy-subrc = 0.
              APPEND dl_string TO dt_data.
              CLEAR  dl_string.
            ELSE.
              EXIT.
            ENDIF.
          ENDDO.
    *--Close data set
          CLOSE DATASET dg_filename.
        ENDIF.

  • How can change the hair to an image every time and how can save the edit image into albums give me code

    HI, I am small iphone developer,i have one problem in my app,please give the guidence to me.
    THIS IS MY PROBLEM:
              I HAVE SELECTED ONE PICTURE FROM ALBUMS OR TAKE PICTURE FROM CAM SO I WANT TO CHANGE THE HAIR STYLES PART WITH ANOTHER HAIR STYELS AND SAVE THE PICTURE INTO ALBUMS HOW CAN GENRATE THE CODE OR LOGIC TO ME......I AM TRYING IT FROM 3WEEKS SO COULD YOU PLEASE GIVE ME GUIDENCE TO ME.................

    HI, I am small iphone developer,i have one problem in my app,please give the guidence to me.
    THIS IS MY PROBLEM:
              I HAVE SELECTED ONE PICTURE FROM ALBUMS OR TAKE PICTURE FROM CAM SO I WANT TO CHANGE THE HAIR STYLES PART WITH ANOTHER HAIR STYELS AND SAVE THE PICTURE INTO ALBUMS HOW CAN GENRATE THE CODE OR LOGIC TO ME......I AM TRYING IT FROM 3WEEKS SO COULD YOU PLEASE GIVE ME GUIDENCE TO ME.................
    Sir I am did it by using Objcetive-C code in iphone as fallows
    demoprojectViewController.h
    #import <UIKit/UIKit.h>
    @interface demoprojectViewController : UIViewController<UIImagePickerControllerDelegate,UINavigationControllerDelegate >
        UIImageView *imageView,*editingimage,*maskimage;
         UIButton *takePictureButton;
        UIButton *selectFromCameraRollButton;
        UIView *myview;
    @property(nonatomic,retain)IBOutlet UIImageView *imageView;
    @property(nonatomic,retain)IBOutlet UIImageView *maskimage;
    @property(nonatomic,retain)IBOutlet UIImageView *editingimage;
    @property(nonatomic,retain)IBOutlet UIButton *takePictureButton;
    @property(nonatomic,retain)IBOutlet UIButton *selectFromCameraRollButton;
    @property(nonatomic,retain )IBOutlet UIView *myview;
    - (IBAction)getCameraPicture:(id)sender;
    - (IBAction)selectExistingPicture;
    -(IBAction)pickHair:(id)sender;
    -(IBAction)done;
    -(IBAction)back;
    @end
    demoprojectViewController.m
    #import "demoprojectViewController.h"
    @implementation demoprojectViewController
    @synthesize imageView,editingimage,maskimage;
    @synthesize takePictureButton;
    @synthesize selectFromCameraRollButton;
    @synthesize myview;
    CGFloat lastScaleFactor = 1;
    CGFloat netRotation;
    CGPoint netTranslation;
    NSArray *images;
    int imageIndex = 0;
    - (void)didReceiveMemoryWarning
        // Releases the view if it doesn't have a superview.
        [super didReceiveMemoryWarning];
        // Release any cached data, images, etc that aren't in use.
    #pragma mark - View lifecycle
    // Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
    - (void)viewDidLoad
       // maskimage=[[UIImageView alloc]initWithFrame:CGRectMake(50, 50, 150, 150)];
        //maskimage.image=[UIImage imageNamed:@"1.png"];
        if ([UIImagePickerController isSourceTypeAvailable:
              UIImagePickerControllerSourceTypeCamera]) {
            takePictureButton.hidden = NO;
            selectFromCameraRollButton.hidden = NO;
           UITapGestureRecognizer *tapGesture =
            [[UITapGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handleTapGesture:)];
            tapGesture.numberOfTapsRequired = 1;
            [maskimage addGestureRecognizer:tapGesture];
            [tapGesture release];
            UIPinchGestureRecognizer *pinchGesture =
            [[UIPinchGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handlePinchGesture:)];
            [maskimage addGestureRecognizer:pinchGesture];
            [pinchGesture release];
            ///---rotate gesture---
            UIRotationGestureRecognizer *rotateGesture =
            [[UIRotationGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handleRotateGesture:)];
            [maskimage addGestureRecognizer:rotateGesture];
            [rotateGesture release];
            //---pan gesture---
            UIPanGestureRecognizer *panGesture =
            [[UIPanGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handlePanGesture:)];
            [maskimage addGestureRecognizer:panGesture];
            [panGesture release];
            //---swipe gesture---
            images = [[NSArray alloc] initWithObjects:
                      @"1.png",
                      @"2.png",
                      @"3.png", nil];
            //---right swipe (default)---
            UISwipeGestureRecognizer *swipeGesture =
            [[UISwipeGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handleSwipeGesture:)];
            [maskimage addGestureRecognizer:swipeGesture];
            [swipeGesture release];
            //---left swipe---
            UISwipeGestureRecognizer *swipeLeftGesture =
            [[UISwipeGestureRecognizer alloc]
             initWithTarget:self
             action:@selector(handleSwipeGesture:)];
            swipeLeftGesture.direction = UISwipeGestureRecognizerDirectionLeft;
            [maskimage addGestureRecognizer:swipeLeftGesture];
            [swipeLeftGesture release];
        [super viewDidLoad];
    -(IBAction) handleTapGesture:(UIGestureRecognizer *) sender {
        if (sender.view.contentMode == UIViewContentModeScaleAspectFit)
            sender.view.contentMode = UIViewContentModeCenter;
        else
            sender.view.contentMode = UIViewContentModeScaleAspectFit;
    -(IBAction) handlePinchGesture:(UIGestureRecognizer *) sender {
        CGFloat factor = [(UIPinchGestureRecognizer *) sender scale];
        if (factor > 1) {
            //---zooming in---
            sender.view.transform = CGAffineTransformMakeScale(
                                                               lastScaleFactor + (factor-1),
                                                               lastScaleFactor + (factor-1));
        } else {
            //---zooming out---
            sender.view.transform = CGAffineTransformMakeScale(
                                                               lastScaleFactor * factor,
                                                               lastScaleFactor * factor);
        if (sender.state == UIGestureRecognizerStateEnded){
            if (factor > 1) {
                lastScaleFactor += (factor-1);
            } else {
                lastScaleFactor *= factor;
    //---handle rotate gesture---
    -(IBAction) handleRotateGesture:(UIGestureRecognizer *) sender {
        CGFloat rotation = [(UIRotationGestureRecognizer *) sender rotation];
        CGAffineTransform transform = CGAffineTransformMakeRotation(
                                                                    rotation + netRotation);
        sender.view.transform = transform;
        if (sender.state == UIGestureRecognizerStateEnded){
            netRotation += rotation;
    //---handle pan gesture---
    -(IBAction) handlePanGesture:(UIGestureRecognizer *) sender {
        CGPoint translation =
        [(UIPanGestureRecognizer *) sender translationInView:maskimage];
        sender.view.transform = CGAffineTransformMakeTranslation(
                                                                 netTranslation.x + translation.x,
                                                                 netTranslation.y + translation.y);
        if (sender.state == UIGestureRecognizerStateEnded){
            netTranslation.x += translation.x;
            netTranslation.y += translation.y;
    -(IBAction) handleSwipeGesture:(UIGestureRecognizer *) sender {
        UISwipeGestureRecognizerDirection direction =
        [(UISwipeGestureRecognizer *) sender direction];
        switch (direction) {
            case UISwipeGestureRecognizerDirectionUp:
                NSLog(@"up");
                break;
            case UISwipeGestureRecognizerDirectionDown:
                NSLog(@"down");
                break;
            case UISwipeGestureRecognizerDirectionLeft:
                imageIndex++;
                break;
            case UISwipeGestureRecognizerDirectionRight:
                imageIndex -- ;
                break;
            default:
                break;
        imageIndex = (imageIndex < 0) ? ([images count] - 1):
        imageIndex % [images count];
        imageView.image = [UIImage imageNamed:
                           [images objectAtIndex:imageIndex]];
    #pragma mark -
    - (IBAction)getCameraPicture:(id)sender {
        UIImagePickerController *picker =
        [[UIImagePickerController alloc] init];
        picker.delegate = self;
        //picker.allowsImageEditing = YES;
        picker.sourceType = (sender == takePictureButton) ?
        UIImagePickerControllerSourceTypeCamera :
        UIImagePickerControllerSourceTypeSavedPhotosAlbum;
        [self presentModalViewController:picker animated:YES];
        [maskimage removeFromSuperview];
        [picker release];
    - (IBAction)selectExistingPicture {
        if ([UIImagePickerController isSourceTypeAvailable:
             UIImagePickerControllerSourceTypePhotoLibrary]) {
            UIImagePickerController *picker =
            [[UIImagePickerController alloc] init];
            picker.delegate = self;
            picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
            [self presentModalViewController:picker animated:YES];
            [maskimage removeFromSuperview];
            [picker release];
        else {
            UIAlertView *alert = [[UIAlertView alloc]
                                  initWithTitle:@"Error accessing photo library"
                                  message:@"Device does not support a photo library"
                                  delegate:nil
                                  cancelButtonTitle:@"Drat!"
                                  otherButtonTitles:nil];
            [alert show];
            [alert release];
    #pragma mark -
    - (void)imagePickerController:(UIImagePickerController *)picker
            didFinishPickingImage:(UIImage *)image
                      editingInfo:(NSDictionary *)editingInfo {
        imageView.image = image;
        [picker dismissModalViewControllerAnimated:YES];
    - (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker {
        [picker dismissModalViewControllerAnimated:YES];
    - (IBAction)btnSave_Clicked:(id)sender;
        UIImageWriteToSavedPhotosAlbum(editingimage.image, nil, nil, nil);
        //UIImageWriteToSavedPhotosAlbum(imageView.image, nil, nil, nil);
        UIAlertView *alert = [[UIAlertView alloc]initWithTitle:@"Success" message:@"Image saved successfully to iPhone photo albums..." delegate:nil cancelButtonTitle:@"Ok" otherButtonTitles:nil];
        [alert show];
        [alert release];
    -(IBAction)pickHair:(id)sender;
           //[maskimage setMultipleTouchEnabled:YES];
       // [maskimage setUserInteractionEnabled:YES];
        //[maskimage setContentMode:UIViewContentModeScaleAspectFit];
        maskimage.image=[UIImage imageNamed:@"1.png"];
        [imageView addSubview:maskimage];
    -(IBAction)done
        NSLog(@"hiafjdkfj");
        UIGraphicsBeginImageContext(imageView.image.size); 
        CGRect rect1 = CGRectMake(netTranslation.x,netTranslation.y,maskimage.image.size.width , maskimage.image.size.height);
        CGRect rect = CGRectMake(0, 0, imageView.image.size.width, imageView.image.size.height);
        [imageView.image drawInRect:rect]; 
        [maskimage.image drawInRect:rect1]; 
        UIImage *resultingImage = UIGraphicsGetImageFromCurrentImageContext(); 
        UIGraphicsEndImageContext(); 
        [editingimage setImage:resultingImage];
        [myview addSubview:editingimage];
        [self.view addSubview:myview];
    -(IBAction)back
        [myview removeFromSuperview];
        //[editingimage removeFromSuperview];
    -(void) touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
        UITouch *touch = [[event allTouches] anyObject];
        CGPoint location = [touch locationInView:touch.view];
        maskimage.center = location;
    -(void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
        [self touchesBegan:touches withEvent:event];
    - (void)viewDidUnload
        self.imageView = nil;
        self.maskimage=nil;
        self.takePictureButton = nil;
        self.selectFromCameraRollButton = nil;
        [super viewDidUnload];
        // Release any retained subviews of the main view.
        // e.g. self.myOutlet = nil;
    - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceO rientation
        // Return YES for supported orientations
        return (interfaceOrientation == UIInterfaceOrientationPortrait);
    - (void)dealloc {
        [imageView release];
        [images release];
        [takePictureButton release];
        [selectFromCameraRollButton release];
        [super dealloc];
    @end
    but i can not put the hair to the proper place means on edit image when am saving the image please help meee

Maybe you are looking for

  • PERFORMANCE IMPROVEMENT for a DB view

    Hi, There is around 300000 entries with MDBS and we are having very slow access and low performance. Following is the query. ima61v internal table does have only single entry in a sample run. SELECT wemng menge wepos elikz umrez              umren ma

  • Text wont appear in indesign cs5.5

    im trying to start a new document but when i draw a text box and try to either type or paste in text nothing comes up, the courser wont even move to its not that the text is invisible it just isnt there in the first place?

  • Iam using a MacBook Pro OSX10.6.8. Can i update to

    I am using an Mac Book Pro with Prcessor 2.33 Ghz intelcore 2 DUO / Memory 3 GB 667 Nhz DDR2 SDRAM  and i just today found that Apple stops supporting  OSX 10.6.8. Is it possibel to update  to  lion or Maverick?

  • Where did Xcode go???

    Hi All, I just downloaded and installed Xcode 2.4, the installation process was ok. But when I tried to find the Xcode icon (the little hammer) in Developer>Applications, I couldn't find it. Previously I had Xcode 2.5 (and I was able to see the icon)

  • Suppress headings if no rows returned

    Hi Like any simple report, I have heading and data being returned in my report. However, I do not wish to display the headings if no data is returned. I have tried the following but that doesnt seem to work. 1)Have heading outside the repeating frame