openmedialibrary_platform_w.../Lib/site-packages/win32/Demos/dde/ddeclient.py
2016-04-14 21:54:42 +02:00

19 lines
451 B
Python

# 'Request' example added jjk 11/20/98
import win32ui
import dde
server = dde.CreateServer()
server.Create("TestClient")
conversation = dde.CreateConversation(server)
conversation.ConnectTo("RunAny", "RunAnyCommand")
conversation.Exec("DoSomething")
conversation.Exec("DoSomethingElse")
conversation.ConnectTo("RunAny", "ComputeStringLength")
s = 'abcdefghi'
sl = conversation.Request(s)
print('length of "%s" is %s'%(s,sl))