CompuServe Messages

VB Question

    03-Oct-91 10:11:23
Sb: VB Question
Fm: Jim Dalin 72260,1573
To: All
I have what I can only assume is a dumb beginner's question about VB. In fact, it's a set of what I can only assume are interrelated questions. To be fair (to myself), I have, indeed, read the manual, but I just cant figure out what to do. What I'm trying to do is this: I have a form to be used to enter a name and address, up to 5 lines. So I created a five-line control array with five identical text boxes. So far, so good. You can enter text on all five lines, but have to press TAB to get from the end of one line to the start of the next, since the Enter key is not recognized (it just generates a beep). So I seem to need to write a "KeyPress" subroutine to look for the Enter key (ASCII 13) and then go to the start of the next line. Question: How do I get to the beginning of the next line? To phrase the same question a different way: how do I "internally generate" a Tab character? Related Question: more generally, how do I cause the cursor to go to some arbitrary spot of my choosing? Another related example: the user enters all five lines, then realizes they wish to wipe out line 3. So I wrote a (simple) routine to clear line 3 (obviously, by setting its .text characteristic = ""). But now I want to put the cursor back to the beginning of the line so the user can retype the line. How do I do that? Thanks in advance for your help. Jim Dalin