Re: String too long...
- From: "Tony Jollans" <My forename at my surname dot com>
- Date: Mon, 29 Jan 2007 06:51:09 -0000
All you need to do is:
(range).Select
But why do you want to use the Selection?
--
Enjoy,
Tony
"mike" <m@xxxxx> wrote in message news:uUlwFkzQHHA.1860@xxxxxxxxxxxxxxxxxxxxxxx
Yes I understand that, thanks Tony.
Now if we wanted to make your code use a variable safely, then next step might be...
Dim myString As String
myString = "this is what I want there"
If Len(myString) < 255 Then
(range).Text = myString
End If
If we want to expand on your example further, you might say we arrive at my question... How do we do the the Else?
If Not Len(myString) < 255 Then
(range).Text = myString
Else
Selection.Idunno = (range).Idunno
Selection.TypeText myString
End If
Thanks again, - Mike
"Tony Jollans" <My forename at my surname dot com> wrote in message news:%23TRjG2wQHHA.2076@xxxxxxxxxxxxxxxxxxxxxxx
The KB article you refer to relates to FormFields but you don't say you are.
working with FormFields so I'm not entirely sure what you want but the
equivalent of TypeText is simply ..
(range).Text = "this is what I want there"
--
Enjoy,
Tony
"mike" <m@xxxxx> wrote in message
news:uRNAZowQHHA.4252@xxxxxxxxxxxxxxxxxxxxxxx
Awfully sorry, it had been a terribly long week, with lot's of time
pressures. I wasn't able to proof-read the note and on second look it surely
needed it. I'll Try again...
I am maintaining an application and am a bit new working with Word Objects.
The Microsoft example in the link provided below seems to work well as a
solution for one particular section of the application that I am working on.
I have implemented Selection.TypeText immediately after performing
Selection.Find & .Execute, as an alternative to their Selection.GoTo
bookmark example.
http://support.microsoft.com/kb/181110
I am now in another section of the code that I am maintaining and am not
able to obtain the safety benefits of Selection.TypeText. That is this
particular section of code happens to be working with the Range object,
however I would like to apply the TypeText solution.
How might one go about implementing this Microsoft example, if working with
the results of a Range.Find & Execute?
Something to the affect of...
If Range.Find then
Selection.Idunno = Range.Idunno
Selection.TypeText (String((256, "W"))
End If
- Mike
- Follow-Ups:
- Re: String too long...
- From: mike
- Re: String too long...
- References:
- String too long...
- From: mike
- Re: String too long...
- From: mike
- Re: String too long...
- From: Tony Jollans
- Re: String too long...
- From: mike
- String too long...
- Prev by Date: Re: String too long...
- Next by Date: Re: Spell checking
- Previous by thread: Re: String too long...
- Next by thread: Re: String too long...
- Index(es):
Relevant Pages
|
Loading