Results 1 to 6 of 6

Thread: Textbox API????

  1. #1

    Thread Starter
    Fanatic Member rudvs2's Avatar
    Join Date
    Mar 2001
    Location
    NZ
    Posts
    935

    Textbox API????

    Hi all

    Does anyone know if there is a way (API I ASSUME) to force a text box to multiline mode dynamically during runtime??

    This is a read only property at run time so trying to change it the conventional way doesnt work

    also it would be usefull to be able to dynamically add the scrollbars during run time as well

    Thanks for any feedback

  2. #2
    Need-a-life Member Mc Brain's Avatar
    Join Date
    Apr 2000
    Location
    Buenos Aires, Argentina
    Posts
    6,808
    Why don't you set it as Multiline = True in design time?
    Emiliano F. Martín


    If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
    Encourage the person who helped you to keep doing it, and give him the points he deserves.


    MP3 Organizer: Freeware to logically organize all your MP3s.

  3. #3
    Need-a-life Member Mc Brain's Avatar
    Join Date
    Apr 2000
    Location
    Buenos Aires, Argentina
    Posts
    6,808
    Whenever you want your textbox not to be multiline, remove all the vbCrLf from it.
    Emiliano F. Martín


    If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
    Encourage the person who helped you to keep doing it, and give him the points he deserves.


    MP3 Organizer: Freeware to logically organize all your MP3s.

  4. #4

    Thread Starter
    Fanatic Member rudvs2's Avatar
    Join Date
    Mar 2001
    Location
    NZ
    Posts
    935
    thanks Mc Brain but thats no use to me

    Im actually trying to create a custom control that has a textbox in it

    I need the custom control to be able to set the properties of the textbox

    Now becasue the textbox multiline and scrollbars properties are read only at run time i cant do this using the normal methods in the custom control

    Thats why i was hoping I could do it via a windows hook or API routine

  5. #5
    Need-a-life Member Mc Brain's Avatar
    Join Date
    Apr 2000
    Location
    Buenos Aires, Argentina
    Posts
    6,808
    Well... that puts things into perspective. Well, I guess the only solution (if no API exists) would be to create your own textcontrol.... for your custom control. That would be weird: A custom control, for your custom control.
    Emiliano F. Martín


    If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
    Encourage the person who helped you to keep doing it, and give him the points he deserves.


    MP3 Organizer: Freeware to logically organize all your MP3s.

  6. #6

    Thread Starter
    Fanatic Member rudvs2's Avatar
    Join Date
    Mar 2001
    Location
    NZ
    Posts
    935
    Originally posted by Mc Brain
    Well... that puts things into perspective. Well, I guess the only solution (if no API exists) would be to create your own textcontrol.... for your custom control. That would be weird: A custom control, for your custom control.
    Doh!!

    Umm that sounds like waaaayyyyyyy to much hard work lol

    I might have a solution already though

    I have found an api that counts number of lines in a textbox and one that tells you what line you are on

    I might combine the two api methods to create a scroll effect and have a vbcrlf trap routine which fires if i have a multiline property set to false

    This then brings me to my next question.

    Does anyone have any experience with creating custom scrollbars??

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width