Select Case help

  • Thread starter Thread starter tr2usa
  • Start date Start date
T

tr2usa

I am trying this select case work but as soon as I put "Universal"
debug msg is coming up. My Form is called Container_Details follow up
and storing data in to tblContainer_Info. Can some one help me please.
Vedat

Private Sub Forwarder_AfterUpdate()
Dim strName As String
strName = Forms!Container_Details![Forwarder].Value
strName = UCase(strName)
Froms!Container_Details![Forwarder].Value = strName (This line is
highlighted as adebug)

Select Case (strName)
Case "UNIVERSAL":
Froms!Container_Details![Phone].Value = "(***) ***-***"
Froms!Container_Details![Contact].Value = "Al"
Case Else:
Forms!Container_Details![Forwarder] = ""

End Select
End Sub
 
I am trying this select case work but as soon as I put "Universal"
debug msg is coming up. My Form is called Container_Details follow up
and storing data in to tblContainer_Info. Can some one help me please.
Vedat

Private Sub Forwarder_AfterUpdate()
Dim strName As String
strName = Forms!Container_Details![Forwarder].Value
strName = UCase(strName)
Froms!Container_Details![Forwarder].Value = strName (This line is
highlighted as adebug)

Select Case (strName)
Case "UNIVERSAL":
Froms!Container_Details![Phone].Value = "(***) ***-***"
Froms!Container_Details![Contact].Value = "Al"
Case Else:
Forms!Container_Details![Forwarder] = ""

End Select
End Sub

Did you copy and paste that code right out of your form? Because you
repeatedly use the word "Froms" when you should be writing "Forms".
 
Thank you very much. I did not pay attention the typing while entering
the info.

Dirk said:
I am trying this select case work but as soon as I put "Universal"
debug msg is coming up. My Form is called Container_Details follow up
and storing data in to tblContainer_Info. Can some one help me please.
Vedat

Private Sub Forwarder_AfterUpdate()
Dim strName As String
strName = Forms!Container_Details![Forwarder].Value
strName = UCase(strName)
Froms!Container_Details![Forwarder].Value = strName (This line is
highlighted as adebug)

Select Case (strName)
Case "UNIVERSAL":
Froms!Container_Details![Phone].Value = "(***) ***-***"
Froms!Container_Details![Contact].Value = "Al"
Case Else:
Forms!Container_Details![Forwarder] = ""

End Select
End Sub

Did you copy and paste that code right out of your form? Because you
repeatedly use the word "Froms" when you should be writing "Forms".

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)
 
Back
Top