StrokesPlus Forum
                       
StrokesPlus Forum
Home | Profile | Register | Active Topics
Members | Search | FAQ
 All Forums
 Lua Scripts
 General Action Scripts
 Snapshot of an area

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Gauchero Posted - 02/14/2019 : 05:19:05
Hi there
I'would have an similary function of the Snip Screen Area action of https://www.strokesplus.net/. The code is there:

quote:
// Copies the area within the square gesture area to the clipboard, like a screenshot

//Delay to ensure S+ has cleared the gesture and hint
sp.Sleep(100);
//Create a new Bitmap in memory
var memoryImage = new drawing.System.Drawing.Bitmap(action.Bounds.Width, action.Bounds.Height);
//Create a graphics object associated with the bitmap
var memoryGraphics = drawing.System.Drawing.Graphics.FromImage(memoryImage);
//Copy the screen within the bounding rectangle of the drawn gesture area
//I used a square gesture since that seems more intuitive, but it's not neccessary
memoryGraphics.CopyFromScreen(action.Bounds.X, action.Bounds.Y, 0, 0, action.Bounds.Size);
//Copy the image to the clipboard
clip.SetImage(memoryImage);
memoryGraphics.Dispose();
memoryImage.Dispose();


i figured out:
// -> --
sp.Sleep(100); -> acDelay(100)

but need help by the memory and clipping part. Anybody can help me?
Thanks in advanced and kind regards
2   L A T E S T    R E P L I E S    (Newest First)
Gauchero Posted - 02/14/2019 : 08:44:57
Hi Rob
Thanks for your the information. I'll find a workaround then, or do it like till now with snagit.. :-D
Rob Posted - 02/14/2019 : 08:03:23
Those are .net framework classes/functions which S+ is not exposed to. I don't think there's any way to accomplish this S+.net functionality in S+, unfortunately.

StrokesPlus Forum © 2011-2018 Rob Yapchanyk Go To Top Of Page
Snitz Forums 2000