Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » RichText,QTF,RTF... » page numbering
Re: page numbering [message #5276 is a reply to message #5275] Tue, 12 September 2006 11:34 Go to previous messageGo to previous message
zsolt is currently offline  zsolt
Messages: 698
Registered: December 2005
Location: Budapest, Hungary
Contributor
luzr wrote on Tue, 12 September 2006 11:29

Ooops, sorry. But at least, I would insert "else" between two variants ("$$PD"):

String  Report::FormatHF(const char *s, int pageno)
{
	String result;
	while(*s) {
		if(s[0] == '$' && s[1] == '$') {
			if(s[2] == 'P'){
				result.Cat(Format("%d", pageno + 1));
				s += 3;
			}
                  else
			if(s[2] == 'D'){
				result.Cat(Format(GetSysDate()));
				s += 3;
			}
		}
		result.Cat(*s++);
	}
	return result;
}


Yes, good idea. I wanted to pu that else also, but you were faster Smile
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: How to insert and display *.png file in UWord and/or qtf??
Next Topic: report / qtf to pdf saving
Goto Forum:
  


Current Time: Mon May 13 05:10:09 CEST 2024

Total time taken to generate the page: 0.01716 seconds