Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Append Text to Memo and Destroy Memo

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1667

PostPosted: Wed Feb 01, 2017 12:00 am    Post subject: Append Text to Memo and Destroy Memo Reply with quote

Hi there,

I trying using a memo

Code:

script1 = [[
This is sample using cheat engine.
About how to get text from text boxes
]]

input = UDF1.CEEdit1.Text

script2 = string.format("Make sure this "..input.." placed under a function on your cheat table")

function GetScript()
 local form = createForm( true );
 control_setCaption(form, [[Output Script]])
 form.width = 800;
 form.height = 800;
 local memo = createMemo(form)
 control_setPosition(memo, 0,0)
 memo.width = 800
 memo.height = 800
 memo.Lines.Text = script1
 memo.append = script2 ------ need correction
end

function resetMemo()
--- if memo created then destroy or delete memo class
end



I want get result when GetScript() execute :

Code:

This is sample using cheat engine.
About how to get text from text boxes
..
..
-- add text from script2


How use append in memo class and also delete memo class (if exist created by GetScript() function) under function resetMemo()

Any hints will be appreciated, thanks
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 457

Joined: 09 May 2003
Posts: 25262
Location: The netherlands

PostPosted: Wed Feb 01, 2017 3:26 am    Post subject: Reply with quote

append: (easiest)
Code:

memo.Lines.Text=memo.Lines.Text..[[

]]..script2


alternatively, use a second offscreen memo, load it's Lines.Text property with script2, and then append line by line from the offscreen memo to memo


as for resetting the memo:
Code:

memo.Clear()

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1667

PostPosted: Wed Feb 01, 2017 3:29 am    Post subject: Reply with quote

Work properly and done.
And how to add scroll bar ?. Sorry because I never use a memo before.

Thanks DB
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 457

Joined: 09 May 2003
Posts: 25262
Location: The netherlands

PostPosted: Wed Feb 01, 2017 3:34 am    Post subject: Reply with quote

Code:

memo.ScrollBars='ssVertical' --or 2


Just look at the form designer for properties and their possible values

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
Corroder
Grandmaster Cheater Supreme
Reputation: 75

Joined: 10 Apr 2015
Posts: 1667

PostPosted: Wed Feb 01, 2017 3:38 am    Post subject: Reply with quote

I got it and thank again DB
Back to top
View user's profile Send private message
MasaruTobi
How do I cheat?
Reputation: 0

Joined: 06 Feb 2017
Posts: 0
Location: sfs

PostPosted: Mon Feb 06, 2017 9:05 pm    Post subject: Reply with quote

Very good
_________________
fsfsdfsdfsdfsdfdsfdsfdsfdsfdsfsdfsdfjkhfghklllklkvcvklbvcbcvjlkbcvbvc
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites