FAQFAQ   SearchSearch   UsergroupsUsergroups   RegisterRegister   ProfileProfile    Log inLog in   RSS Feed

Question about SendMessage() function.

 
Post new topic   Reply to topic    Salling Software Forums Forum Index -> Scripting Salling Clicker for Windows
View previous topic :: View next topic  
Author Message
szakalit
Newbie


Joined: 13 Apr 2006
Posts: 11

PostPosted: Thu Apr 13, 2006 12:27 pm    Post subject: Question about SendMessage() function. Reply with quote

First of all hi all :D

I have question about SendMessage(), it is possible to send message with this parameters:

[code:1]
var txtlength = SendMessage(titleHWND, WM_GETTEXTLENGTH, 0, 0);
or
var txt = SendMessage(titleHWND, WM_GETTEXT, 50, title);
[/code:1]
When im trying i always get [object Error] message.

If its possible can someone wirte some example?

Thx
Back to top
View user's profile Send private message
salling
Site Admin


Joined: 27 Jul 2004
Posts: 7498
Location: Stockholm, Sweden

PostPosted: Thu Apr 13, 2006 1:45 pm    Post subject: Re: Question about SendMessage() function. Reply with quote

Hi there,

Please try this instead:

var txt = GetWindowCaption( titleHWND );

(this will pull out and return the window text/caption, up to 1024 bytes worth of it, at least)

Best.
--
Jonas


[quote="szakalit"]First of all hi all :D

I have question about SendMessage(), it is possible to send message with this parameters:

[code:1]
var txtlength = SendMessage(titleHWND, WM_GETTEXTLENGTH, 0, 0);
or
var txt = SendMessage(titleHWND, WM_GETTEXT, 50, title);
[/code:1]
When im trying i always get [object Error] message.

If its possible can someone wirte some example?

Thx[/quote]
Back to top
View user's profile Send private message Send e-mail Visit poster's website
szakalit
Newbie


Joined: 13 Apr 2006
Posts: 11

PostPosted: Thu Apr 13, 2006 3:21 pm    Post subject: Re: Question about SendMessage() function. Reply with quote

[quote="salling"]Hi there,

Please try this instead:

var txt = GetWindowCaption( titleHWND );

(this will pull out and return the window text/caption, up to 1024 bytes worth of it, at least)
[/quote]

Thx, its working :D

Best :D
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Salling Software Forums Forum Index -> Scripting Salling Clicker for Windows All times are GMT + 2 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