我一直在尝试从Excel宏自动化Reflections,代码如下。但是,有2个会话打开,我附上相同的截图供参考。任何人都可以帮助我如何在已经运行的会话之间切换。
Public objFM As Object
Set objFM = GetObject("RIBM") With objFM
.WaitForEvent rcEnterPos, "30", "0", 4, 41
.WaitForDisplayString "code:", "30", 4, 34
.TransmitTerminalKey rcIBMResetKey
.TransmitANSI "MTAE"
.TransmitTerminalKey rcIBMEnterKey
.WaitForEvent rcKbdEnabled, "30", "0", 1, 1
End With