Search found 8 matches

by wg961423
Wed 19 Oct 2022 07:16
Forum: SecureBridge
Topic: TScSFTPClient.UploadFile error in uploading a file
Replies: 0
Views: 111556

TScSFTPClient.UploadFile error in uploading a file

When the server already has the same file name and it is incomplete and needs to be appended, the 3rd parameter of UploadFile is set to false and the upload file will have an error, the file size is fine but the first half of the file is set to 0 and the appended content is placed at the end of the file.

After tracing the code, the code in the TScSFTPClient.OpenAndUploadFile function OpenModes := [foWrite, foCreate, foExcl]; needs to be changed to OpenModes := [foWrite, foCreate, foAppend]; to be able to properly Append the file.
by wg961423
Wed 03 Aug 2022 09:21
Forum: SecureBridge
Topic: TScFTPClient uploads a file of 0 bytes after setting UseCompression to True
Replies: 1
Views: 7776

TScFTPClient uploads a file of 0 bytes after setting UseCompression to True

TScFTPClient was uploading files of 0 bytes after setting UseCompression to True.
After reviewing the source code, the problem can be solved by modifying the TScFTPClient.OnWriteData function as follows
procedure TScFTPClient.OnWriteData(Stream: TStream; const Data: TBytes; Count: integer);
begin
// FDataConnection.Write(TValueArr(Buffer), 0, Count);// This is the original code
FDataConnection.Write(TValueArr(Data), 0, Count);
DoProgress(FTotalUploadSize, FTotalUploadSize - (Stream.Size - Stream.Position));
end;
by wg961423
Tue 26 Jan 2010 07:44
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

In addition, VirtualTable1-> Assign (ADOQuery1); often 'Out of Memory'

System: Windows2003 3G Memory
by wg961423
Tue 26 Jan 2010 07:38
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

Sorry, not this field, and is a Guid, SQL Server in NewID (), XML for type = 'uuid'
by wg961423
Tue 26 Jan 2010 05:25
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

I am sorry, I am wrong, there is this method, but this method to generate the XML file, VirtualTable not re-loaded, loading tips: Data type is not supported.
by wg961423
Fri 15 Jan 2010 02:36
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

Sorry, I think this method does not provide TVirtualTable
by wg961423
Thu 14 Jan 2010 01:42
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

My English is not very good, but others do not have this problem?
I am now using C + + Builder, where has also tried in Delphi, but also have this problem.
by wg961423
Mon 11 Jan 2010 03:45
Forum: VirtualDAC
Topic: Unknown data type FieldDesc.DataType=27
Replies: 7
Views: 7140

Unknown data type FieldDesc.DataType=27

/*
--SQL 2000 or SQL 2005 or SQL 2008
Create table test
(
column1 numeric(14,4)
)
insert into test values(14.55)
*/
TMemoryStream *ms=new TMemoryStream();
ADOQuery1->SQL->Add("select * from test");
ADOQuery1->Open();
VirtualTable1->Assign(ADOQuery1);
VirtualTable1->SaveToStream(ms); <---Unknown data type FieldDesc.DataType=27


//I Use VirtualTable 6.90 for RAD Studio 2010