cancel
Showing results for 
Search instead for 
Did you mean: 

SAPSCRIPT: Initial value

Former Member
0 Kudos

Hi Guys. Im new to sap script and im having a porblem: How do you check if a value is initial?

Im trying to display text and a table field (REGUD-SWRBT) if REGUP-UMSKZ is initial.

Any help appreciated.

Accepted Solutions (0)

Answers (1)

Answers (1)

stefan_schnell
Active Contributor
0 Kudos

Hello Mike,

try this:


Dim FMName
'This is an example for TAC SE37
'session.findById("wnd[0]/tbar[0]/okcd").text = "/nse37"
'session.findById("wnd[0]/tbar[0]/btn[0]").press
'Field function module name
Set FMName = session.findById("wnd[0]/usr/ctxtRS38L-NAME")
'Set FMName = session.findById("wnd[0]/usr/ctxtREGUP-UMSKZ") '< Your field name
If Trim(FMName.text) = "" Then
  FMName.text = "RFC_PING"
Else
  MsgBox "FM-Name is " & FMName.text  
End If

Hope it helps.

Cheers

Stefan