![]() |
#7
|
|||
|
|||
![]()
Got an error I hope you can help....
Im getting Case without select errors and case without select... Would these be better off as separate macros as the first one is functional if I delete the items I added in the check box value areas. I included an updated attachment and you can see the marco below... Form ending in B has the bad macro, none-B form has only the first macro with not checkbox name changes And if this works I would like to also have the selection of the PT or MT box cause the selection of a box in 15 or 16 as applicable. If MT is selected the the last box in 15 and if PT is selected then the first box in 16 is selected. Also, using the machines local date I would like the second block of block 19 and 20 to use the PC's current date. Sub NameDDOnExit() Dim oFF As FormFields Set oFF = ActiveDocument.FormFields Select Case oFF("Name").Result Case "USS Florida SSGN-728" oFF("UIC").Result = "21038" Case "USS Georgia SSGN-729" oFF("UIC").Result = "21039" Case "USS Alaska SSBN-732" oFF("UIC").Result = "21042" Case "USS Tennessee SSBN-734" oFF("UIC").Result = "21044" Case "USS West Virginia SSBN-736" oFF("UIC").Result = "21365" Case "USS Maryland SSBN-738" oFF("UIC").Result = "21460" Case "USS Rhode Island SSBN-740" oFF("UIC").Result = "21682" Case "USS Wyoming SSBN-742" oFF("UIC").Result = "21846" Case "TRF" oFF("UIC").Result = "44466" Case "Triper" oFF("UIC").Result = "00024" Case "CSS-20" oFF("UIC").Result = "63976" Case " " oFF("UIC").Result = " " End Select Case "VT_DIM" Select Case oFF("VT_DIM").CheckBox.Value Case "True" oFF("B11_1").Result = "1C" Case Else oFF("B11_1").Result = "" Case "PT" Select Case oFF("PT").CheckBox.Value Case "True" oFF("B11_2").Result = "4E" Case Else oFF("B11_2").Result = "" Case "MT" Select Case oFF("MT").CheckBox.Value Case "True" oFF("B11_3").Result = "3G" Case Else oFF("B11_3").Result = "" End Select End Select End Sub |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Text Wrapping on Fixed Lines in a Form field/Table cell | okrmjr | Word Tables | 0 | 10-30-2009 08:52 AM |
Outlook 2007, contacts: drop down in custom field | pacecal | Outlook | 0 | 06-16-2009 10:43 AM |
![]() |
Toshii | Word | 1 | 06-08-2009 07:21 PM |
![]() |
Gail L. | Word | 2 | 05-17-2009 12:38 PM |
evaluating a text expression in a form field | gwp1 | Word | 0 | 10-08-2007 02:15 PM |