|
-
Jun 18th, 2000, 10:02 AM
#1
Thread Starter
Member
How Do I Delete Text Using The 'Delete' Key Like Wordpad Does, I Already Have A Dropdown Menu With A Hotkey Of Delete, The Only Problem Is That I Dont Know How To Delete Text Without Getting A Box When I Try To Delete A Carriage Return?
I Think I Might Dont Know The Answer To That One...
-
Jun 18th, 2000, 04:30 PM
#2
Lively Member
please specify what textbox r u using !
or supply some code.
-
Jun 18th, 2000, 06:38 PM
#3
Junior Member
There may be a few options for this one, but as the previous member said, more information is required please.
Regards
We watch in reverence as Narcissus is turned to a flower.
-
Jun 18th, 2000, 08:50 PM
#4
Thread Starter
Member
im using a multilined textbox, and heres the code that i was using that doesnt work -
<-----Code----->
Private Sub Delete_Click
Text1.Sellength = 1
Text1.SelText = ""
End Sub
<-----Code----->
I Think I Might Dont Know The Answer To That One...
-
Jun 18th, 2000, 10:51 PM
#5
Junior Member
Still not quite sure what you are attempting to achieve here. Purely by setting Text1.SelText to "" (omit the line Text1.SelLength = 1) will delete any highlighted text in the text box, and also pressing the delete key will give the same result. You can put that code in a sub routine and call it from your menu routine (or put it directly in the menu control's code). And what is this "box" you are getting when you try to delete a carriage return?
Sorry to be a pain...Please elaborate
We watch in reverence as Narcissus is turned to a flower.
-
Jun 19th, 2000, 08:29 AM
#6
Thread Starter
Member
This box that im talking about is a box that i get when i try to delete something that isnt there (you also get the box in the file when you try to make a Wordpad doc into a text file).Sorry Its Hard To Explain...
I Think I Might Dont Know The Answer To That One...
-
Jun 19th, 2000, 11:45 AM
#7
Lively Member
like an error box?
on error goto hell
'code
'code
'code
hell:
msgbox "on error occured possible cause u screw3d up",,"title"
-
Jun 19th, 2000, 12:13 PM
#8
Thread Starter
Member
No Not A Error Box, Its A Box Inside The Textbox Thats The Size Of A Character.
I Think I Might Dont Know The Answer To That One...
-
Jun 20th, 2000, 06:04 AM
#9
Thread Starter
Member
Yeah Thats What It Is, I Get That Thing When I Try To Delete This(Its Hard To Explain):
----------------------------------
|Hello, How Are You Today, |
|Im Fine. |
----------------------------------
` Hello, How Are You Today, Is Deleted But Right Before Im Fine Takes Its Place I Get
----------------------------------
| |
|Im Fine |
----------------------------------
I Think I Might Dont Know The Answer To That One...
-
Jun 20th, 2000, 07:02 AM
#10
Hold on a sec.
Code:
Private Sub Delete_Click
Text1.Sellength = 1
Text1.SelText = ""
End Sub
you were using this code because your Del key was a Shortcut for a menu? If the menu's purpose is to Delete something, then you should only use Text1.SelText=""
-
Jun 20th, 2000, 10:11 PM
#11
Thread Starter
Member
Yes I Tried That, But When You Try To Delete A Carriage Return, That Rectangle Comes up, And I Dont Want The Rectangle To Come Up.
I Think I Might Dont Know The Answer To That One...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|