Browse Source

Merge branch 'master' of http://git.shengws.com/csx/gdyb

csx 3 years ago
parent
commit
1454937ce1
1 changed files with 4 additions and 4 deletions
  1. 4 4
      service/gdyb_service.go

+ 4 - 4
service/gdyb_service.go View File

@@ -60,7 +60,7 @@ func Gdyb1201(certNo string, org_name string, doctor string, fixmedins_code stri
60 60
 	url := gdyb_url + "1201"
61 61
 	//var str string
62 62
 	//str1 := make([]byte, 1024)
63
-
63
+	s3 := make([]byte, 256)
64 64
 	ole.CoInitialize(0)
65 65
 	unknown, err := oleutil.CreateObject("yinhai.yh_hb_sctr")
66 66
 	if err != nil {
@@ -69,18 +69,18 @@ func Gdyb1201(certNo string, org_name string, doctor string, fixmedins_code stri
69 69
 	xxxx := unknown.MustQueryInterface(ole.IID_IDispatch)
70 70
 
71 71
 	//p := (*string)(unsafe.Pointer(str))
72
-	var str6 *string
72
+	//var str6 *string
73 73
 	if err != nil {
74 74
 		log.Fatal("QueryInterface: ", err)
75 75
 	}
76 76
 
77
-	r, err1 := xxxx.CallMethod("yh_hb_call", "1201", string(bytesData), str6)
77
+	r, err1 := xxxx.CallMethod("yh_hb_call", "1201", string(bytesData), uintptr(unsafe.Pointer(&s3[0])))
78 78
 	if err1 != nil {
79 79
 		log.Fatal("CallMethod: ", err1, " | ", r)
80 80
 	}
81 81
 	fmt.Println("~~~~~~~")
82 82
 	fmt.Println(r)
83
-	fmt.Println(str6)
83
+	fmt.Println(s3)
84 84
 	fmt.Println("~~~~~~~")
85 85
 
86 86
 	xxxx.Release()