Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

strname

ResolvedVersion 2007

Theresa has attended:
Excel VBA Intro Intermediate course

StrName

Hi,

in my selection data my strName currently = theresa.carey@ticketmaster.co.uk (i also have a number of other names in my selection data but don't want to have to input the whole name only first and last name. for example Theresa Carey.

How can i build it into my code to exclude the . @ticketmaster.co.uk?

Let me know if this makes any sense and if not i am happy to send a file across.

Regards
Theresa

RE: strName

Hi Theresa, thanks for your query. Try this out:


***

strname = "theresa.carey@ticketmaster.co.uk"

MsgBox Left(strname, Len(strname) - 19)

***

Hope this helps,

Anthony

Fri 27 May 2011: Automatically marked as resolved.

 

Training courses

Training information:

Welcome. Please choose your application (eg. Excel) and then post your question.

Our Microsoft Qualified trainers will then respond within 24 hours (working days).

Frequently Asked Questions
What does 'Resolved' mean?

Any suggestions, questions or comments? Please post in the Improve the forum thread.

VBA tip:

Stop Display Alerts In Excel

When creating or deleting a Worksheet in Excel you don't want Excel to inform you "A file already exists....." Or "Do you want to save this file...".

To stop these alerts happening use the following line of code:

Application.DisplayAlerts = False

After the Create or Delete routine use:

Application.DisplayAlerts = True

View all VBA hints and tips

Connect with us:

0207 987 3777

Call for assistance

Request Callback

We will call you back

Server loaded in 0.09 secs.