Jump to content

Recommended Posts

Posted

Hi,

 

Im strugling with an old hat problem with multiline textboxes, im programming in VBA and i want to create an emulated console for doing script like querying, however ive tried:-

 

text1.text=text1.text & vbcrlf & ">"

text1.selstart=len(text1.text)

 

but the damn cursor moves to the next line after the ">" eve though i havent made an extra carriage return, any ideas why this is happening?

Posted
Have you tried text1.selstart=len(text1.text) - 1

 

Yes Ive tried -1,-2 ,3 gives error, im not sure if somehow the textbox changes focus after the change of Vbcrlf. the cursor suddenly jumps and creates a CR when i haven't added one.

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



  • 134 What is your preferred operating system (PC)

    1. 1. Operating systems:


      • MacOS
      • Windows 10
      • Windows 11
      • Windows Vista
      • ChromeOS
      • Other (reply)

×
×
  • Create New...