Print Page | Close Window

Report control with markup

Printed From: Codejock Forums
Category: General
Forum Name: XAML Snippets
Forum Description: Post your XAML snippets here for everyone to enjoy :)
URL: http://forum.codejock.com/forum_posts.asp?TID=14776
Printed Date: 26 April 2024 at 6:10pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Report control with markup
Posted By: joeliner
Subject: Report control with markup
Date Posted: 20 July 2009 at 9:50am
Hi guys,

This my scenario,

I would like to use the report control to output to a printer the following format (e.g. print a receipt) which i push to a report control row. The tags are replaced with values from the database and additionally i add a watermarkbitmap to act as the logo. The problem is i cannot print more than one cheque/receipt per page since you can only load one bitmap on the RC per report and not per row. Currently i am using the standard format but i would like to apply markup so that i can also add styling to the text (e.g bold the titles) and probably add a logo that appears on every row. Has someone does this? anyhelp is really appreciated. TIA,.
                                                                 
VAT:  <VATNUMBER>          PIN: <PINNUMBER>

NAME:  <ADDRESS>                                                  <RECEIPTNO>    

                                                       
BEING PAYMENT OF
PAYMENT MODE:  <PAYMODE>


                             <CURRENCY>                                     <RATES>
      

     
                                                                          <AMOUNT>



<WORDS>


RECEIVED WITH THANKS           
                                                                       AUTHORISED SIGNATORY ____________________


-------------
Product: Xtreme SuitePro (ActiveX) version 13.1
Platform: Windows XP SP 3
Language: Visual Basic 6 SP6



Replies:
Posted By: braian87b
Date Posted: 21 July 2009 at 2:26pm
ReportControl Is not must be used for this kind of things...
i recommend you to use a Report Renderer Control, like crystal reports or Active Reports... also, you can try to generate HTML code save to a file... and then print them using a third party control like webbrowser inet activex ( or something like that, from microsoft),

you only could print "tables" "recordsets" "grids" "rows-records" using print's method of RC... not "form like" designed data templates.




-------------
Product: Xtreme SuitePro (ActiveX) version 11.
Platform: Windows XP (32bit) - SP 3
Language: Visual Basic 6.0 SP 6
Spanish, Espaņol, English.
Argentina


Posted By: joeliner
Date Posted: 27 July 2009 at 3:39am
Thanks braian,

Av got my reasons why i wud like it particularly with the report control. For one,  codejock tools make my app pretty light compared to adding third party controls like CrystalReports. More so, i have built a report designer built around RC and thus i just wud like to enhance it by using the Markup that RC support.

I wud be glad to know if i can still implement the above using Markup.

regards,




-------------
Product: Xtreme SuitePro (ActiveX) version 13.1
Platform: Windows XP SP 3
Language: Visual Basic 6 SP6


Posted By: mdoubson
Date Posted: 30 July 2009 at 8:39pm
From Dr. Dobb's update:
great little comic entitled http://links.techwebnewsletters.com/ctt?kn=15&m=33756404&r=MjIxNTU3MjM5MQS2&b=0&j=NTQ0MzM1MDAS1&mt=1&rt=0 - Misunderstanding Markup


-------------
Mark Doubson, Ph.D.


Posted By: wlcabral
Date Posted: 24 October 2012 at 10:00pm
This is what i'm doing, I hope it help:
 
1 - I use VS2010 to create the basic layout of each column of my report. I can create everything in a single cell or in several pieces.
 
2- I use "Codejock's MarkupPad" to verify the compatibility of  XAML  tags from VS.
 
3 - I change XAML code to add to my Tags :
 
Image Column :
 <Grid Height="100" HorizontalAlignment="Left"   Name="Grid1" VerticalAlignment="Top" Width="150">
     <Border Height="100" HorizontalAlignment="Left" Name="Border1" VerticalAlignment="Top" Width="150" Background="White" BorderBrush="#FF1FA3EB" BorderThickness="0,0,0,0">
         <Image Name="Image1" Stretch="Uniform" Width="140" Source="<<D04_032_M>>" Margin="2" Height="76" />
     </Border>
 </Grid>
 
Info Column :
 <Grid Height="100" HorizontalAlignment="Left"   Name="Grid1"   Width="550">
    
     <TextBlock Height="47" HorizontalAlignment="Left" Margin="399,5,0,0" Name="TextBlock6" Text="<<D03_002_C>>" TextWrapping="Wrap" VerticalAlignment="Top" Width="95" />
     <TextBlock Height="43" HorizontalAlignment="Left" Margin="399,60,0,0" Name="TextBlock4" Text="<<T21_002_C>>" TextWrapping="Wrap" VerticalAlignment="Top" Width="95" />
     <TextBlock Foreground="#FF1FA3EB"  HorizontalAlignment="Left" Height="20" Margin="5,5,0,0" Name="TextBlock2" Text="<<D04_008_C>>"   Width="384" />
     <TextBlock        HorizontalAlignment="Left" Height="20" Margin="5,60,0,0" Name="TextBlock1" Text="<<D04_001_C>>"  Width="290"   />
 </Grid>
 
4 - I set up the RC properties to work with XAML

.EnableMarkup = .T.

.PaintManager.FixedRowHeight = .F.
.PaintManager.HorizontalGridStyle = xtpGridSolid

Finnaly - I merge the Database Information with XAML. In my case I'm usign MS Visual Foxpro :
item(1).caption = TextMerge(Image Column )
item(2).caption = TextMerge(Info Column )
 
-----
 
 


-------------
wlcabral


Posted By: vicos
Date Posted: 01 February 2013 at 2:23pm
Can share your example please?



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net