Bạn có thể xác định và viết giản đồ trong mô-đun/thường trình phụ theo định dạng tệp muốn tải lên. mô-đun/thói quen phụ này phải được chạy/gọi điện để tạo ra sơ đồ trước khi bạn chạy upload .. (mẫu của tôi đang sử dụng VB6)
Lưu ý: - Filenametxt là tên file mà muốn được tải lên
IntFileHandleLog = FreeFile
Open App.Path & "schema.ini" For Output As #IntFileHandleLog
Print #IntFileHandleLog, "[" & FileNameTxt & "]"
Print #IntFileHandleLog, "Format=FixedLength"
Print #IntFileHandleLog, "MaxScanRows = 0"
Print #IntFileHandleLog, "CharacterSet = OEM"
Print #IntFileHandleLog, "Col1=" & """" & "Name" & """" & "Text Width 20"
Print #IntFileHandleLog, "Col2=" & """" & "PHONE_NUM" & """" & " Text Width 30"
Print #IntFileHandleLog, "Col3=" & """" & "PHONE_TYPE" & """" & " Text Width 20"
Print #IntFileHandleLog, "col4=" & """" & "UserName" & """" & " Text Width 20"
Print #IntFileHandleLog, "col5=" & """" & "A_STAT" & """" & " Text Width 10"
Print #IntFileHandleLog, "col6=" & """" & "B_STAT" & """" & " Text Width 10"
Print #IntFileHandleLog, "col7=" & """" & "RETRY" & """" & "integer width 2"
Print #IntFileHandleLog, "col8=" & """" & "Birth_Date" & """" & " double width 14"
Print #IntFileHandleLog, "Col9=" & """" & "Joint_Date" & """" & " double width 14"
Close #IntFileHandleLog
Nó sẽ xuất hiện ở trên * ý tưởng không hoạt động, không ai có một gợi ý tốt hơn? –