Forum Discussion

stevereissps's avatar
stevereissps
Occasional Contributor
4 years ago

Picture.SaveToFile() - Remove Cursor from Image?

Hi All,   I am trying to use picture.SaveToFile(fileName) to save a table image to a .PNG file.    I need to have the cursor removed from the image, as this is causing the Picture diffing to fail...
  • AlexKaras's avatar
    4 years ago

    Hi,

     

    Something like this:

    // Move mouse out of view

    Sys.Desktop.MouseX = Sys.Desktop.Width;

    Sys.Desktop.MouseY = Sys.Desktop.Height / 2;

     

    // Take a picture excluding mouse pointer

    var pic = Aliases.Compass_for_SW.Main_ToolBar.Graph_Area.Composite.Level_1.Level_2.CTabFolder2.Picture(0, 0, -1, -1, false);

     

    // Save picture to file

    pic.SaveToFile(...);

     

    Does it help?