Writing Code
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Writing Code
Message Icon Topic: Why can NOT get proper margin value in crystal rep Post Reply Post New Topic
Author Message
ryanelee
Newbie
Newbie


Joined: 02 Jul 2008
Online Status: Offline
Posts: 1
Quote ryanelee Replybullet Topic: Why can NOT get proper margin value in crystal rep
    Posted: 03 Jul 2008 at 2:15am
hi All,

   I have a crystal report in vs 2008, the top margin is 0.5 inch I pre-setting in page setup, I'd like to reset it in c#, the code sample like this:
       PageMargins margins;

       margins = myReport.PrintOptions.PageMargins;
       margins.topMargin=margins.topMargin+15;
                 
       myReport.PrintOptions.ApplyPageMargins(margins);

   I can get the topMargin which is 720px in vs 2003, but its value is -2147483648 in vs 2008.And it seems the top margin pre-defined is efficient when I preview in design time in vs 2008, why I can NOT get the proper margin value via the same code in vs 2008?
   Anybody encounterred this? Please help.

Thanks in advance!
Ryan Lee
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.