A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Create a shortcut for repetitive text



 
 
Thread Tools Display Modes
  #1  
Old October 12th, 2009, 08:18 PM posted to microsoft.public.excel.misc
Deej Hernandez[_2_]
external usenet poster
 
Posts: 34
Default Create a shortcut for repetitive text

I have Office 2007 Home Edition running on a laptop with Vista Home Premium.
I run a football pool every season and would like to know if there is any way
to create shortcuts for all of the team names/division so that I don't have
to type all 32 names with division every week. For example right now I have
to completely type Denver (AFC West) for every game during the season and
possible postseason games also. Is there anything I can create to use in
Excel so that I just have to type one or two letters and it will put in the
whole name?
  #2  
Old October 12th, 2009, 09:04 PM posted to microsoft.public.excel.misc
Gary''s Student
external usenet poster
 
Posts: 7,584
Default Create a shortcut for repetitive text

Say we need to enter team names in column A of some worksheet, but we would
like to enter only a two digit numbers and have a translation automatically
be performed. First enter this event macro in the worksheet code area:

Private Sub Worksheet_Change(ByVal Target As Range)
Dim Team(1 To 32) As String
Team(1) = " Buffalo Bills (AFC-East)"
Team(2) = " Miami Dolphins (AFC-East)"
Team(3) = " New England Patriots (AFC-East)"
Team(4) = " New York Jets (AFC-East)"
Team(5) = " Baltimore Ravens (AFC-North)"
Team(6) = " Cincinnati Bengals (AFC-North)"
Team(7) = " Cleveland Browns (AFC-North)"
Team(8) = " Pittsburgh Steelers (AFC-North)"
Team(9) = " Houston Texans (AFC-South)"
Team(10) = " Indianapolis Colts (AFC-South)"
Team(11) = " Jacksonville Jaguars (AFC-South)"
Team(12) = " Tennessee Titans (AFC-South)"
Team(13) = " Denver Broncos (AFC-West)"
Team(14) = " Kansas City Chiefs (AFC-West)"
Team(15) = " Oakland Raiders (AFC-West)"
Team(16) = " San Diego Chargers (AFC-West)"
Team(17) = " Dallas Cowboys (NFC-East)"
Team(18) = " New York Giants (NFC-East)"
Team(19) = " Philadelphia Eagles (NFC-East)"
Team(20) = " Washington Redskins (NFC-East)"
Team(21) = " Chicago Bears (NFC-North)"
Team(22) = " Detroit Lions (NFC-North)"
Team(23) = " Green Bay Packers (NFC-North)"
Team(24) = " Minnesota Vikings (NFC-North)"
Team(25) = " Atlanta Falcons (NFC-Souch)"
Team(26) = " Carolina Panthers (NFC-Souch)"
Team(27) = " New Orleans Saints (NFC-Souch)"
Team(28) = " Tampa Bay Buccaneers (NFC-Souch)"
Team(29) = " Arizona Cardinals (NFC-West)"
Team(30) = " St. Louis Rams (NFC-West)"
Team(31) = " San Francisco 49'ers (NFC-West)"
Team(32) = " Seattle Seahawks (NFC-West)"
If Intersect(Target, Range("A:A")) Is Nothing Then Exit Sub
Application.EnableEvents = False
v = Target.Value
Target.Value = Team(v)
Application.EnableEvents = True
End Sub

If you now type 3 in a cell in column A it will become:

New England Patriots (AFC-East)

--
Gary''s Student - gsnu200907


"Deej Hernandez" wrote:

I have Office 2007 Home Edition running on a laptop with Vista Home Premium.
I run a football pool every season and would like to know if there is any way
to create shortcuts for all of the team names/division so that I don't have
to type all 32 names with division every week. For example right now I have
to completely type Denver (AFC West) for every game during the season and
possible postseason games also. Is there anything I can create to use in
Excel so that I just have to type one or two letters and it will put in the
whole name?

  #3  
Old October 12th, 2009, 09:26 PM posted to microsoft.public.excel.misc
Gary Keramidas
external usenet poster
 
Posts: 118
Default Create a shortcut for repetitive text

you could set up an autocorrect for each one:

replace nyg with New York Giants (NFC East)

-

Gary Keramidas
Excel 2003


"Deej Hernandez" wrote in message
...
I have Office 2007 Home Edition running on a laptop with Vista Home Premium.
I run a football pool every season and would like to know if there is any way
to create shortcuts for all of the team names/division so that I don't have
to type all 32 names with division every week. For example right now I have
to completely type Denver (AFC West) for every game during the season and
possible postseason games also. Is there anything I can create to use in
Excel so that I just have to type one or two letters and it will put in the
whole name?


  #4  
Old October 12th, 2009, 10:02 PM posted to microsoft.public.excel.misc
Dave Peterson
external usenet poster
 
Posts: 19,791
Default Create a shortcut for repetitive text

You may want to dump excel completely.

There are tons of sites that do this already. ESPN, Yahoo, ...



Deej Hernandez wrote:

I have Office 2007 Home Edition running on a laptop with Vista Home Premium.
I run a football pool every season and would like to know if there is any way
to create shortcuts for all of the team names/division so that I don't have
to type all 32 names with division every week. For example right now I have
to completely type Denver (AFC West) for every game during the season and
possible postseason games also. Is there anything I can create to use in
Excel so that I just have to type one or two letters and it will put in the
whole name?


--

Dave Peterson
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 09:00 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.