What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Script question and 2 msn questions.

Script question and 2 msn questions.
Author: Message:
CookieRevised
Elite Member
*****

Avatar

Posts: 15517
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: Script question and 2 msn questions.
quote:
Originally posted by GNSPS
Yes, there is a way to limit the amount of characters to enter in a textbox in a MP!L window, all you have to do is to edit the XML file or the script's code in order for them to don't allow more characters than those specified.
IIRC there is no way to specify the maximum amount of characters you can enter in an EditControl directly in the XML; there are no attributes for it.

However, you can specify the maximum amount by sending the EM_SETLIMITTEXT or EM_LIMITTEXT windows message (both are identical) to the control by using the Plus! scripting function: PlusWnd::SendControlMessage.

See Official Plus! Scripting Documentation.

eg:
code:
// create window with id 'Information'
var wndExample = MsgPlus.CreateWnd('interface.xml', 'Information');     
// send windows message EM_LIMITTEXT (constant value 0xC5) to the control with id 'PhoneNumber'
wndExample.SendControlMessage('PhoneNumber', 0xC5 /* EM_LIMITTEXT */, 9 /* maximum allowed characters */, 0 /* not used */)

This post was edited on 07-21-2007 at 05:11 PM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
07-21-2007 04:58 PM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Script question and 2 msn questions. - by Ashylay on 07-21-2007 at 02:07 PM
RE: Script question and 2 msn questions. - by _Humphreys on 07-21-2007 at 02:10 PM
RE: Script question and 2 msn questions. - by GNSPS on 07-21-2007 at 02:34 PM
RE: Script question and 2 msn questions. - by CookieRevised on 07-21-2007 at 04:58 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On