Hi.
I am trying to replace space with hard space in i string variable.
I found that space was chr(32) but I haven't been able to find the ascii
code for hard space. The bookmark is in the footer section so I can't use
ordinary find/replace.
The code I am trying to use is:
Dim var As String
Dim ferdig As String
var = "Hei dette er Hege"
ferdig = Replace(var, Chr(32), Chr(?), 1, Len(var))
ActiveDocument.Bookmarks("Test").Range.Text = ferdig
If anyone know what to put insted of ? or have an alternative way of doing
this I would be very grateful.
Hege
Philippe boudreau - 04 Jul 2005 16:22 GMT
Quick Google search gave me this..
...The hard space is ascii character 160 or A0h (hexadecimal) ...
HTH
P.
> Hi.
>
[quoted text clipped - 14 lines]
>
> Hege
Hege M - 04 Jul 2005 17:45 GMT
Hi!
Great, no it works. Thank you.
(I'll search Google before I ask next time)
Hege
Philippe boudreau skrev:
> Quick Google search gave me this..
> ....The hard space is ascii character 160 or A0h (hexadecimal) ...
[quoted text clipped - 21 lines]
> >
> > Hege