String manipulation in VBA 
Author Message
 String manipulation in VBA


Over the last year I've had problems with Left at some occasions on a
certain client machine, Word97, SR1, Win95. Only last week it occurred.
After rebooting the problem disappeared. No third-party controls has been
used on the particular workstation, from what I know.

/Anna Bohman
Bra Utbildning AB, Sundsvall, Sweden


>Hi Greg,
>The one time I heard of this happening was when using a beta version of a
>third-party VB control, and control had a Left property. Setting the
>compiler options wrong when compiling the control meant that the Left
>property interfered with the Left() function of VBA. Using the VBA
>was the workaround until a fix was made (fortunately very quickly)

>Jonathan West - Word MVP
>MultiLinker - Automated generation of hyperlinks in Word
>Conversion to PDF & HTML
> http://www.*-*-*.com/
>Word FAQs at http://www.*-*-*.com/
>Please post any follow-up in the newsgroup. I do not reply to Word
>by email

- Show quoted text -


>>I didn't really investigate why, but I had similar problems with some vba
>>functions and used the library qualifier, hence, VBA.Chr instead of plain


>>Greg Longtin

>>> Jonathan

>>> Thanks. Those are the common ones. The problem is long gone but the
>>> occurred at every Errorhandler containing a MsgBox with Chr(13) in the
>>> there was a problem at the customers office,  NT4, Word97. Replacing it
>>> vbCr made the difference. Doesn't make sense to me.

>>> --
>>> /Anna Bohman
>>> ------------------------------------------------------------------------
>>> Bra Utbildning AB, Sundsvall, Sweden

>>> ------------------------------------------------------------------------

Tue, 09 Jul 2002 03:00:00 GMT  
 String manipulation in VBA

Use the vbTab constant...

> Hi,

> I am writing a function in VBA and I'm interested in writing a string
> composed of a couple of words separated by a 'tab' key.
> In pure Visual Basic I wrote the following:

> dim str as String
> str = "aaa" + Chr(9) + "bbb"

> However, in VBA the function 'Chr()' is not recognized.
> Do you know any other way I can use to mark the tab key? (I tried \t, it
> didn't work) Or maybe how can I make my VBA environment familiar with this
> function?

> I will appreciate any hint you can give,
> Thanks in advance,

> Shoshi.

Fri, 12 Jul 2002 03:00:00 GMT  
 [ 17 post ]  Go to page: [1] [2]

 Relevant Pages 

Powered by phpBB® Forum Software