>>>Help..
>>>
>>>Does anyone know how to programmatically set the tab width inside an EditBox control. I tried using the foxTool _EdGetEnv() and _EdSetEnv() function but apparently they only work with an edit window such as MODIFY FILE.
>>>
>>>I have a form that contains an editbox control whose controlsource is a memo field in a table. When the uses goes into the editbox control to make changes to the text I would like to set the tab width to 2.
>>>
>>>Any ideas ?
>>>
>>>Thanks
>>
>>Would it be sufficient for you to intercept TAB key in Keypress and send SPACE(2) instead?
>
>That's not a tab and it's a hassle to re-indent later. I think the original poster wanted to change the displayed width of a tab in the editor - something we usually set in the preferences.
But it's still feasible solution, and even 'unidenting' is possible to some extent (STRTRAN etc.).
>The other thing is that the question itself is too interesting to go for a Q&D solution. I'm also curious to know what can we do to get into these _ed* functions. I don't want to write an editor, but at times I'd like to have more power over what user can do, can be prevented from doing, and can be enabled to do in an editor window. Imagine a procedure which would add
and
tags around selected text :). I know how would I do that, but in an editbox only. In a Modify File/Prog window, I wouldn't know.
I guess I know too for EditBox. 'Modify' Window is not an object, that's the problem.
Edward Pikman
Independent Consultant