Delphi 7 to Delphi XE: TBlobField to XML [Edit]

Hi,
I'm migrating a Delphi7 application to Delphi XE.
I'm using a TClientDataSet to communicate,  by using a XML frame, with my server.
In this TClientDataSet I'm using a TBlobField which is an array of 384 byte.
The blobField is allocate by a code like this :
{code}
  myStream : TStream;
  myStream := aClientDataSet.CreateBlobStream(myBlobField, bmwrite);
  vResult := myStream.Write(ArrayOf384Byte[0], length(ArrayOf384Byte)); //vResult = 384 => GooD !
  (...)
{code}
For communicate with the server, we have to decode the Blobfield in XML before to sending it.
We have override the ApplyUpdate. In the new applyupdate, we are converting NewValue in base64 by a code like this :

{code}  aXmlString := StringToBase64(myBlobField.NewValue) {code}

The problem is than in Delphi 7 the length of NewValue was correct (384), but in DXE this length is random (between 50 and 250 ??) (it's as if a character was an end of string)
=> There is data loss, so the XML string is bad and my server is crashing. 
I don't understand what happened between writing in the BlobField and reading the BlobField's property "newValue"??? 
Why the value was correct in Delphi 7 and bad in XE? 
What was changed in the ClientDataSet mechanism? 
Is it a problem of unicode migration?

Any help will be appreciated.

Thanks,

Gwen

Edited by: Gwénaël Manceau on Oct 20, 2011 9:46 AM
0
Utf
10/20/2011 4:47:05 PM
embarcadero.delphi.xml 291 articles. 0 followers. Follow

1 Replies
3828 Views

Similar Articles

[PageSpeed] 17

I solved my problem by using 
{code}  aXmlString := StringToBase64(myBlobField.AsString) {code} instead of 
{code}  aXmlString := StringToBase64(myBlobField.NewValue){code}
0
Utf
10/25/2011 12:20:17 PM
Reply:

Similar Artilces:

Delphi 7 to Delphi XE
Have been using Delphi 7 for many moons ( have got later versions but never upgraded to ) My first problem is: Component Palette. in XE it is a small toolbar docked in top right in Delphi 7 it gives a large view of all the components. I am struggling to be able to cope/access my components.in Delphi XE. Can I make the component pallette tool bar the same size as Delphi 7, or is there a fast way to view/choose all available components in XE, that I have not spotted yet? Kind Regards, Robert. Hi, What I know is that in Delphi 2010 and XE you can choose between t...

Convert Delphi 7 to Delphi 2009 [Edit]
Hi! Please, I have a code done in Delphi 7... Now I want to convert Delphi 7 to Delphi 2009 but I'm having problems when compile the code. Error message: +[DCC Fatal Error] Far.dpr(9): F2063 Could not compile used unit 'System.pas'+ Please can somebody help me? Source Download (349KB): http://rapidshare.com/files/256191328/FileManager.rar.html Mirror Source Download: http://www.megaupload.com/?d=12GYLPT0 Password: delphi Thank u so much! (sorry for my bad english, it is not my native language) Edited by: loquax loquax on Jul 15, 2009 12:24 PM Sorry, bu...

Migrating to Delphi XE from Delphi 7.0
Below is my code in Delphi 7.0, this is how to call another units in webmodule... Hello All, I create a web application in Delphi 7.0, using the Web Server Application, CGI, IntraWeb 7.0.15. And I used TIWPageProducer to view like this url "http://localhost/mcr/mcr.exe/main". I built and run. I viewed in thru IIS and it is running... This is my code in Delphi 7.0 .... .... procedure TWebModule1.proMainGetForm(ASender: TIWPageProducer; AWebApplication: TIWApplication; var VForm: TIWPageForm); begin VForm := TfrmMain.Create(AWebApplication); end; procedure TWebModule1....

Migrating to Delphi XE from Delphi 7.0
Below is my code in Delphi 7.0, this is how to call another units in webmodule... Hello All, I create a web application in Delphi 7.0, using the Web Server Application, CGI, IntraWeb 7.0.15. And I used TIWPageProducer to view like this url "http://localhost/mcr/mcr.exe/main". I built and run. I viewed in thru IIS and it is running... This is my code in Delphi 7.0 .... .... procedure TWebModule1.proMainGetForm(ASender: TIWPageProducer; AWebApplication: TIWApplication; var VForm: TIWPageForm); begin VForm := TfrmMain.Create(AWebApplication); end; procedure TWebModule1.proLogInGetForm(ASender: TIWPageProducer; AWebApplication: TIWApplication; var VForm: TIWPageForm); begin VForm := TfrmLogIn.Create(AWebApplication); end; ..... .... Now I Upgrade to Delphi XE.... Below is my Code in Delphi XE and There is no IWTPageProducer instead I used TPageProducer... {*************************************************} unit uWebModule; interface uses SysUtils, Classes, HTTPApp, HTTPProd, SOAPHTTPDisp, WebBrokerSOAP, IWAppForm, IWApplication; type TfrmWebModule = class(TWebModule) PageProducer1: TPageProducer; . . . private public end; var WebModuleClass: TComponentClass = TfrmWebModule; AWebApplication: TIWApplication; implementation uses uMain; {$R *.dfm} procedure TfrmWebModule.frmWebModuleactMainAction(Sender: TObject; Request: TWebRequest; Response: TWebRes...

Migrating from Delphi 6 to Delphi XE 3! [Edit]
All, I am a Delphi developer working in an windows form application developed using Delphi 6. Now, we are planning to upgrade the development tool. Can anyone provide me information related to major roadblocks that we can face while migrating from Delphi 6 to Delphi XE 3? Should we migrate to Delphi XE 3 or any other preferred version of Delphi based on the fact that our target users will be using Windows 7 or Windows 8? Do we have any tools or utilities to migrate the source code from Delphi 6 to higher version of Delphi? Also, any suggestions related to best practices are welcome....

Code works in Delphi 7 but not in Delphi 2010 [Edit]
hello, i have a procedure that open's a file by passing the file name as the parameter to the executable. something like this {code} C : \ P r o g r a m F i l e s \ Da c k e r \ D r a c k e r . e x e " G : \ D E l p h i 7 \ D e l p h i 7 A p p _ l o g . t " {code} The source code is {code} procedure OpenFileWithExe var hReg: HKEY; Ret: Longint; RegDataType, RegDataSize: DWORD; CmdLine: array [0..560] of Char; Len: Integer; SInfo: TStartupInfo; PInfo: TProcessInformation; begin Ret := windows.RegOpenKeyEx(HKEY_CURRENT_USER, ...

Delphi 7.0 code convert to delphi XE ...
Hello All, I create an application using Web Server Application then CGI stand alone... In WebModule I add ModuleController component and IWPageProcedure... Below is my code in Delphi 7.0, this is how to call another units in webmodule... .... .... procedure TWebModule1.proMainGetForm(ASender: TIWPageProducer; AWebApplication: TIWApplication; var VForm: TIWPageForm); begin VForm := TfrmMain.Create(AWebApplication); end; procedure TWebModule1.proLogInGetForm(ASender: TIWPageProducer; AWebApplication: TIWApplication; var VForm: TIWPageForm); begin VForm := TfrmLogIn.Create(AWebA...

Delphi 7 to Delphi XE2
Hi, Still using that old workhorse, Delphi7, but am going to the conference in London hosted by Embarcadero on Delphi XE2. Although I would like to "move with the times" and am keen to get the UNICODE and 64-bit support offered by the latest IDEs, I confess to being more than a little scared about all the UNICODE/String/AnsiString and 32/64 bit issues I'm probably going to fall over. Anyone recently upgraded from Delphi7 to one of the latest Delphi IDEs? Thanks, Alain On 03/02/2012 08:55, Alain Dekker wrote: > Still using that old workhorse, Delphi7, but am going to the conference in > London hosted by Embarcadero on Delphi XE2. > > Although I would like to "move with the times" and am keen to get the > UNICODE and 64-bit support offered by the latest IDEs, I confess to being > more than a little scared about all the UNICODE/String/AnsiString and 32/64 > bit issues I'm probably going to fall over. Anyone recently upgraded from > Delphi7 to one of the latest Delphi IDEs? I recently upgraded a sizeable (Paradox) app from D3 to XE2 and was pleasantly surprised. About 20-30 hours once I understood how XE2 works. Andrew -- Andrew Gabb email: agabb@tpgi.com.au Adelaide, South Australia phone: +61 8 8342-1021 ----- Recently moved a lexicographic application from D2007 to XE2 with little pain. As you would imagine, it is heavily string-based, with much use of TStringLists, cuttin...

Delphi XE / Delphi 2010
Hello! I noticed that Embarcadero® Delphi® 2010 Version is not on the list of products on Embarcadero page. Or is it still possible to buy it? Will RAD Studio XE compile programs written in Delphi 2010 without problems.? Thanks. Am 13.09.2010 09:04, schrieb Petra Nemec: > Will RAD Studio XE compile programs written in Delphi 2010 without problems.? As always you will probably have to recreate the projects as the import is still a bit -- special. Christian Hello! Does anybody know if it is still possible to get a Delphi2010 trial version (if yes where)? ...

Delphi 2007 to Delphi 7
I've written a class in Delphi 2007 that is not supported in Delphi 7. What would be the best way to achive what I've done in Delphi 2007 in Delphi 7? Thanks, Tom type BondConstants = class { Bond Types } type BondType = record const TREASURY = 3; AGENCY = 0; CORP = 1; MUNI = 2; SBA = 5; MBS = 4; CMO = 6; end; { Day Count Methods } type DayCount = record const ACTUAL_360 = 2; ACTUAL_365 = 1; ACTUAL_ACTUAL = 1; d30_360 = 0; ...

XML, RTTI-based serialization for Delphi 7? [Edit]
Using Delphi 7. Trying to export a tcollection of data to XML to load later. I've used the JVCL, NativeXML, and OmniXML. So far OmniXML has worked the best.. its ALMOST there...but since it looks discontinued.. and OXML doesn't have this feature yet.. Only issue I have with OmniXML.. is each tcollection item, has a smaller object inside them. Everything else saves/loads fine.. but I really need the smaller object inside those to save out also. Any one have any ideas on this? NativeXML looked promising, but it gets AV errors trying to save my tcollection object. Edited by: steven chesser on Oct 27, 2014 1:00 PM Edited by: steven chesser on Oct 28, 2014 12:41 PM Use OXml http://www.kluug.net/oxml.php It's excellent, as is the support. Cross-platform also (NativeXML is good but Windows only). I'm using OXml in a couple of projects for RTTI-based serialization. Cheers, Bob Den 10/27/2014 21:01, steven chesser skrev: > Using Delphi 7. > > Trying to export a tcollection of data to XML to load later. > > I've used the JVCL, NativeXML, and OmniXML. > > So far OmniXML has worked the best.. its ALMOST there...but since it looks discontinued.. and OXML doesn't have this feature yet.. > > Only issue I have with OmniXML.. is each tcollection item, has a smaller object inside them. > > Everything else saves/loads fine.. but I really need the smaller object inside those to save ...

SEPA components for Delphi with Source Code (Delphi 5
Hi all, in the european union change next year the Bankingformat to the SEPA Format. All peoples and companies must change the bankingssoftware and the costumer data form acountnummers in the new IBAN and BIC numbers. See: http://www.arma-it.de/shop/artikelueber.php?wgruppeid=211&wgruppe_offen=211 Functions: - generate SEPA XML'S - Calc IBAN - BIC Database (DE,AT and CH) Questions: vertrieb@arma-it.de PS: Bankinssoftware for Develpoers (Germany only) http://www.arma-it.de/shop/artikelueber.php?wgruppeid=212&wgruppe_offen=212 El 26/10/13 21:38, A...

ShowMessage/MessagDlg wordwrap Delphi 2006
Hi, I have used Delphi 2006 up to now. ShowMessage allowed a long text without a word wrapping. Now with Delphi XE I notice that a migrated program shows smaller message window sizes and a previously carefully aligned message now appears wrapped and misaligned. How to get back to the previous behaviour? I'm not experienced to create my custom form, so a code snippet may help. Thanks, Uli Edited by: Ulrich Brueggemann on Sep 18, 2010 8:46 AM > I have used Delphi 2006 up to now. > ShowMessage allowed a long text without a word wrapping. > > Now with Delphi ...

How to access Delphi 7 & 2009 after purchasing Delphi XE
I have purchased and installed Delphi XE and now I'm unable to find information on how to download previous versions of Delphi, namely Delphi 7 and 2009. Please respond. Regards, SB, L&T Hi sushweta biswas, > I have purchased and installed Delphi XE and now I'm unable to find information on how to download previous versions of Delphi, namely Delphi 7 and 2009. Your reseller should have told you: after registering Delphi XE, you can go to http://www.embarcadero.com/xe-earlier-versions to enter your serial number of Delphi XE as well as your EDN account informati...

Delphi 2006 to Delphi XE Crystal BPL problem [Edit]
I am in the process of migrating our application from Delphi 2006 to Delphi XE and, for ease of use, I have both 2006 and XE installed on my development computer. I access Crystal Reports XI RDC in our application and so I rebuilt the BPL in XE in order to add the new package to XE. However, when I try to add the package to XE I get the error message: “Registration procedure, Craxddrt_tbl.Register in the package c:\Documents and Settings\All Uers\Documents\RADS Studio\8.0\BPL\Crystal.bpl raised exception class EFilerError: Component TDatabase can’t be registered by package crystal.bpl because it has already been registered by the package dclbde150.bpl.” In other words, since I already have the Crystal RDC registered for 2006, I can’t register it for XE. I realize that I could move XE to a different computer, but I would really like to keep both versions on the same note book. Does anyone have any suggestions on how to get around this problem? Thank you in advance, Dave ...

Problem upgrading web service client from Delphi 7 to Delphi XE
In trying to upgrade our web service client to Delphi XE we have now get a web service error of Invalid Format. When we examine the SOAP request we see the following differences from Delphi 7 vs Delphi XE In Delphi 7 we get <SomeStuff xmlns="" xsi:nil="true" /> In Delphi XE we get <SomeStuff xsi:nil="true" /> We have narrowed the failure down to these differences in the client request. Is there anyway to get Delphi XE to generate a SOAP request with the xmlns attribute set to blank as it used to be? Hello, > In trying to upgrade our web service client to Delphi XE we have now get a > web service error of Invalid Format. > > When we examine the SOAP request we see the following differences from > Delphi 7 vs Delphi XE > > In Delphi 7 we get > > <SomeStuff xmlns="" xsi:nil="true" /> > > In Delphi XE we get > > <SomeStuff xsi:nil="true" /> > > We have narrowed the failure down to these differences in the client > request. Is there anyway to get Delphi XE to generate a SOAP request with > the xmlns attribute set to blank as it used to be? In general XE offers more flexibility on how to encoding the XML. For a non-nil node one can tag an element/parameter as unqualified to have the xmlns=""' attribute using the IS_UNQL flag. I would need to know more about 'SomeStuff'...

Delphi and Delphi for .Net
It seems that Delphi for .Net is slower than Delphi Win32 native applicaiton. I would like to know is it true all .Net application is slower than Win32 native applicaiton or it is Delphi for .Net only. Your information is great appreciated, Inung On 2011-06-21 18:20:17 +0100, Inung Huang said: > It seems that Delphi for .Net is slower than Delphi Win32 native applicaiton. > I would like to know is it true all .Net application is slower than > Win32 native applicaiton or it is Delphi for .Net only. If you are only running the code in the application once then, yes, yo...

Delphi 7 to Delphi 2009 conversion
Hello group, What do I need to do to comile the following code in D2009. Compiler error after the Else E2010: Incompatible Types 'AnsiChar' and 'Char' if isUnicode then SearchHandle := FindFirstFilew( PWideChar( fn ), FindDataW ) else SearchHandle := FindFirstFile( PAnsiChar( Ansistring( fn ) ), FindDataA ); <<<<<compiler error in the above line >>>>>>>>>>> Regards, Bryan > What do I need to do to comile the following code in D2009. > Compiler error after the Else > E2010: Incompati...

Delphi 2007 RTL in Delphi 7
I read somewhere that it is possible to use Delphi 2007's (or for that matter Delphi 2006's) RTL in Delphi 7 by just recompiling the source of RTL. Is this really possible? What are the benefits that we can derive using a higher version's RTL? TIA Yogi Yang Yogi Yang wrote: > I read somewhere that it is possible to use Delphi 2007's (or for > that matter Delphi 2006's) RTL in Delphi 7 by just recompiling the > source of RTL. If it actually compiles in Delphi 7, I guess it would be possible. OTOH, if one has Delphi 2007 already, I don't s...

Moving from Delphi 7 to Delphi 2007
Is there any compelling reason to move (quite a large project) from Delphi 7 to Delphi 2007? Specifically, is there better Vista/Win7/Win8 integration provided by Delphi 2007? (In the project I am already using a custom manifest file for Vista/Win7 etc.. and not the std XPMan component) Does 2007 add any new bugs to the scene? Thanks Rael Rael wrote: > Is there any compelling reason to move (quite a large project) from > Delphi 7 to Delphi 2007? If you are going to upgrade, why not upgrade to something newer? > In the project I am already using a custom man...

Migrating From Delphi 7 to Delphi 2010
We did not know which forum was the best for this question. We have been wanting to migrate from Delphi 7 to a later version for years but it appears to be a daunting task. We first looked at D2006 and that was a radical new world. We bought D2010 a couple of years ago and not done much with it because there are so many parts to our applications. We have done a few new applications in D2010 and they seem to work okay. D2010 has not been impressive, perhaps because of the strangeness compared to D7. Is is possible for us to do a phased sort of migration where we do a form at a time? ...

Using Delphi 7 and Delphi 2010
I had a project in Delphi 7. I worked on it in Delphi 2010. When I try to open the .dpr again in Delphi 7, the IDE toolbar widens across both monitors, and Delphi 7 locks up. It appears that Delphi 2010 modifies the .dpr in a way that makes Delphi 7 unable to open it again. All my forms & units appear to open fine in D7 after D2010, except for the warnings on the ExplicitHeight and ExplicitWidth properties being missing... I can easily recreate the .dpr, but is this expected behavior? Thanks. Tom Field wrote: > I had a project in Delphi 7. > > I worked o...

Migrating from Delphi 7 to Delphi XE3
Hello, Its time to leave the old Delphi 7 and move to the new (but not the latest) XE3. I was wondering if there is a good book or reference to learn all new things XE3 added. Any suggestions? On 5/3/2013 10:17 PM, George Karatsiolis wrote: > Hello, Its time to leave the old Delphi 7 and move to the new (but not the latest) XE3. > I was wondering if there is a good book or reference to learn all new things XE3 added. Try this one for starters: http://tinyurl.com/cgsu243 Aside from that you really need to evaluate your application. XE3 is Unicode for example.... So her...

I wrote an application and used cracked delphi 7, after i bought delphi 7
I wrote an application and used cracked delphi 7, I sold it, after i bought delphi 7 and recompiled application, is now my application legal or? > {quote:title=Ivan Ivanov wrote:}{quote} > I wrote an application and used cracked delphi 7, I sold it, after i bought delphi 7 and recompiled application, is now my application legal or? "I embezzled some money from my employer, returned the funds, and then got it back as a bonus. Can I still be arrested?" Uhhh .... didn't you just confess to a crime? > {quote:title=Ivan Ivanov wrote:}{quote} > I wrote an application and used cracked delphi 7, I sold it, after i bought delphi 7 and recompiled application, is now my application legal or? Is there any legalization rules of embarcadero products? > {quote:title=Ivan Ivanov wrote:}{quote} > > Is there any legalization rules of embarcadero products? What does the license agreement say? (I don't think I've ever seen a license agreement that has amnesty clauses written into it.) Why do you think you violated the license? Were you caught? Do you WANT to be caught? Do you WANT to be sued? Thanks David that you answer my question, my english is too poor, can you tell me where is written about amnesty in licence, thanks in advance Am 29.12.2011 19:22, schrieb Ivan Ivanov: > Thanks David that you answer my question, my english is too poor, can you tell me where is written about amnesty in licence, thanks in adv...

Web resources about - Delphi 7 to Delphi XE: TBlobField to XML [Edit] - embarcadero.delphi.xml

Resources last updated: 3/18/2016 2:29:53 AM