Due to enormous amounts of spam, the forum has been set to read-only mode.



Reply to topic  [ 40 posts ]  Go to page 1, 2, 3, 4  Next
GenerateHTML Not Returning RecordsetGUID 
Author Message

Joined: Thu Jul 31, 2003 8:21 pm
Posts: 1433
Post GenerateHTML Not Returning RecordsetGUID

Next issue: GenerateHTML is not returning a RecordsetGUID. My code is as follows. Any ideas?

Code:

function TCatraxx.GetHTML(const XSLTemplate, Filter: WideString;
  StripLinks: WordBool; var RecordsetGUID: WideString): widestring;
var
  ItemType: string;
  TempString, ResultString: widestring;
  TempFile: widestring;
  i: integer;
begin
  try
    TempFile:=NewTempFile(GetTempDirectory, '', 'html');
    FDataServer.GenerateHTML(XSLTemplate, Filter, False, TempFile, RecordSetGUID);
    TempString:=ReadTextFile(TempFile);
    Result:=TempString;
  finally
    SysUtils.DeleteFile(TempFile);
  end;
end;


- Jeff


Thu Aug 13, 2009 12:12 am
Profile
User avatar

Joined: Fri Nov 14, 2003 6:15 pm
Posts: 1425
Post Re: GenerateHTML Not Returning RecordsetGUID

Jeff, GenerateHTML returns the GUID just fine for me. Wish I could help with your code but I don't use Delphi.

Image

_________________
Cheers,
Dave


Thu Aug 13, 2009 5:13 am
Profile WWW
Site Admin
User avatar

Joined: Fri Nov 22, 2002 3:52 pm
Posts: 13748
Post Re: GenerateHTML Not Returning RecordsetGUID

JSonnabend1 wrote:
Next issue: GenerateHTML is not returning a RecordsetGUID. My code is as follows. Any ideas?

Works fine here. Is the html file generated? Are you using D2007 or D2009?

_________________
Fredrik Nordbakke
www.fnprg.com


Thu Aug 13, 2009 1:32 pm
Profile WWW

Joined: Thu Jul 31, 2003 8:21 pm
Posts: 1433
Post Re: GenerateHTML Not Returning RecordsetGUID

I'm using D6. Should that matter?

- Jeff


Thu Aug 13, 2009 2:12 pm
Profile

Joined: Thu Jul 31, 2003 8:21 pm
Posts: 1433
Post Re: GenerateHTML Not Returning RecordsetGUID

Oh, and yes, the HTML file is generated. Everything is working but the GUID generation. This problem is killing me right now.

- Jeff


Thu Aug 13, 2009 4:20 pm
Profile
User avatar

Joined: Sat Nov 22, 2003 7:47 pm
Posts: 2547
Location: Denmark
Post Re: GenerateHTML Not Returning RecordsetGUID

Jeff,

Which parametervalues are passed?

_________________
Kind regards
Thomas Hamstrup

HAP Software (http://www.hamstrup.dk)

Using Windows 8 PRO 64-bit and CATraxx 9.44


Thu Aug 13, 2009 4:26 pm
Profile WWW

Joined: Thu Jul 31, 2003 8:21 pm
Posts: 1433
Post Re: GenerateHTML Not Returning RecordsetGUID

Thomas, I'm not sure I follow the question. Do you mean the values of each parameter to the GenerateHTML function?

- Jeff


Thu Aug 13, 2009 4:35 pm
Profile
User avatar

Joined: Sat Nov 22, 2003 7:47 pm
Posts: 2547
Location: Denmark
Post Re: GenerateHTML Not Returning RecordsetGUID

Yes.

_________________
Kind regards
Thomas Hamstrup

HAP Software (http://www.hamstrup.dk)

Using Windows 8 PRO 64-bit and CATraxx 9.44


Thu Aug 13, 2009 4:40 pm
Profile WWW

Joined: Thu Jul 31, 2003 8:21 pm
Posts: 1433
Post Re: GenerateHTML Not Returning RecordsetGUID

It hasn't mattered, and the HTML page is being generated properly. For example:

Template: tracklist.xsl
Filter: artist=radiohead@orderby=length,title
StripLinks: false
GUID: blank


Thu Aug 13, 2009 4:51 pm
Profile
User avatar

Joined: Sat Nov 22, 2003 7:47 pm
Posts: 2547
Location: Denmark
Post Re: GenerateHTML Not Returning RecordsetGUID

I seem to remember, that I had a similar problem years ago.

I can't remember what I did, but it might be something with the definition of GUID.

If not already, try to define GUID globally in the unit where you call the dataserver, set it to GUID:='' when you begin.

It works perfectly here.

_________________
Kind regards
Thomas Hamstrup

HAP Software (http://www.hamstrup.dk)

Using Windows 8 PRO 64-bit and CATraxx 9.44


Thu Aug 13, 2009 4:57 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 40 posts ]  Go to page 1, 2, 3, 4  Next

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.