OLEObject ole_ADOStream
ole_ADOStream = CREATE OLEObject
li_rtn = ole_ADOStream.ConnectToNewObject("ADODB.Stream")
ole_ADOStream.Position = 0 //Position为0才能设置Charset
ole_adostream.Type = 2 //二进制数据Binary
ole_ADOStream.Mode =3 //具有读/写权限
ole_ADOStream.Charset = "UTF-8"
ole_ADOStream.Open()
ole_ADOStream.WriteText("你的utf_8")
ole_ADOStream.Position = 0 //Position为0才能设置Charset
ole_ADOStream.Type = 2 //文本数据
ole_ADOStream.Charset = "GB2312"
ole_ADOStream.readtext(ls_data) //ls_data即为你想要的东东
ole_ADOStream.Close()
destroy ole_ADOStream
但是PB运行的时候怎么提示找不到 ole_ADOStream的相关属性(Position ,Type ,Mode ,Charset )
大神指点一下什么问题
1 个解决方案
#1
应该是你连接未成功,判断一下
li_rtn = ole_ADOStream.ConnectToNewObject("ADODB.Stream")
li_rtn的返回值
li_rtn = ole_ADOStream.ConnectToNewObject("ADODB.Stream")
li_rtn的返回值
#1
应该是你连接未成功,判断一下
li_rtn = ole_ADOStream.ConnectToNewObject("ADODB.Stream")
li_rtn的返回值
li_rtn = ole_ADOStream.ConnectToNewObject("ADODB.Stream")
li_rtn的返回值