Sign in to follow this  
Followers 0
CyberSlug

Controlcommand, Get Row?

4 posts in this topic

Larry (or whomever), is is possible to add a ControlCommand that gives the current Column of the caret within an Edit control?

[i have a workaround where I select the text preceding the cursor and count the characters, but it's prefer to do it discretely.]


Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

Share this post


Link to post
Share on other sites



My method of getting the caret position just uses an API function along with AttachThreadInput to get it from whichever program is on top (I tried allowing the user to specify a window, but this was a way bad idea and returned... odd results).

That being said, the column is probably something that's calculated internally. I don't see any glaring "Hey I return the column of the caret" functions when I took a look at the API. It might be possible to write a function that could calculate it, but I think the time and effort would be wasted since it would only work on Microsoft controls. I think you're finding out the hard way that a lot of editors don't always respond correctly to those...

Share this post


Link to post
Share on other sites

I forgot to mention that reading the statusbar is a decent workaround.

Anyway, thanks for trying, Valik

I thought of that until I used Au3_Spy on TextPad. :whistle:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0