Can't change section format properties in codebehind

I have the following code in my aspx page:
CrystalDecisions.CrystalReports.Engine.ReportDocument cryRpt = new CrystalDecisions.CrystalReports.Engine.ReportDocument();
cryRpt.Load(path1);
ReportClientDocumentWrapper docWrap = (ReportClientDocumentWrapper)cryRpt.ReportClientDocument;
AddReportDetailsSection(docWrap, detailsA.Width, detailsA.Height, "detailsC");
var detailsC = docWrap.ReportDefController.ReportDefinition.DetailArea.Sections[2];
if (detailsC != null)
      detailsC.Format.EnableNewPageAfter = true;
      detailsC.Format.PageOrientation = CrPaperOrientationEnum.crPaperOrientationLandscape;
      docWrap.SubreportController.ImportSubreport("1sub", path2, detailsC);
var subReports = docWrap.ReportDefController.ReportObjectController.GetReportObjectsByKind(CrReportObjectKindEnum.crReportObjectKindSubreport);
foreach (var subReport in subReports) {
           var iSubReport = subReport as ISCRSubreportObject;
            iSubReport.Border.BottomLineStyle = iSubReport.Border.RightLineStyle
            = iSubReport.Border.TopLineStyle = iSubReport.Border.LeftLineStyle = CrLineStyleEnum.crLineStyleNoLine;
cryRpt.SaveAs(path2);
But when I open saved report via SAP Crystal Reports Developer, i see that subreport was added with borders and details section C formatting wasn't changed. Can somebody tell me, what I'm missing?

HI,
thank you for reply. My CR version is 13.0.2000, VS 2010.
I've found some workaround.
To get report objects i've written such method:
protected static List<T> GetReportObjects<T>(CrystalDecisions.CrystalReports.Engine.ReportDocument report) where T
                                                                                        : class
            List<T> resList = new List<T>();
            IEnumerator re = report.ReportDefinition.ReportObjects.GetEnumerator();
            re.Reset();
            while (re.MoveNext())
                if (re.Current != null)
                    var obj = re.Current as T;
                    if (obj != null)
                        resList.Add(obj);
            return resList;
And then I use it like below:
var subRptObj = GetReportObjects<CrystalDecisions.CrystalReports.Engine.SubreportObject>(rptDoc).Where(s => s.Name.Equals("1sub")).SingleOrDefault();
if (subRptObj != null)
   subRptObj.Border.BottomLineStyle = LineStyle.DotLine;
Maybe, this will help somebody.

Similar Messages

  • How can I change the format of some of the pages of a PDF-document?

    I use Adobe Acrobat and have a PDF-document with A4 pages and some pages of another format (half of an A4).
    How can I change the format of these pages to A4 (with a lower blanc part)?

    You can increase the page size with the Crop Tool of Acrobat Pro.

  • HT4007 I Just updated Apeture to 3.3.2  Now there are some photos that I receive a message..."Unsupported Image Format"  Are there lost?  can I retrieve them?  can I change the format?  Help...?!?

    I just updates Apeture to version 3.3.2 after installing Mountain Lion.  There are some photos in Apeture that now say, "Umsupported Image Format".  Are these lost?  Can I retrieve them...how?  Can I change the format so that I can see them again?  Help?!?

    Are these images "Raw" images? What is the make of your camera?
    Check the version of the Digital Camera RAW Compatibility Update that is installed.  The version of the raw support is shown in the About panel: from the main menu bar:
         Aperture > About Aperture
    Download the latest Raw Update from here:
    Digital Camera RAW Compatibility Update 3.14
    If you have the latest raw support installed, but Aperture does not recognize the format, try to register the raw support for your camera with the launch services db, see this post by Alan Roseman:
               Re: Aperture 3 preview of raw file greenish
    But also read the following post, that explain how this is supposed to work and to correct the typo in the command
    In short: Quit Aperture, open the terminal, paste the  follwing text in (all in one single line) and hit return; then reboot the system.
    /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchSe rvices.framework/Versions/A/Support/lsregister -R /System/Library/CoreServices/CoreTypes.bundle/Contents/Library
    Regards
    Leonie

  • How can I change the formate of @today from (MM/dd/yyy) to (dd-MM-yyyy)?

    I am in openscript, using a settext commend - .setText("{{@today(MM/dd/yyyy), 10-02-2011}}}}"); is anyone know how can I change the formate of @today from (MM/dd/yyy) to (dd-MM-yyyy)?
    I went to Java Code tab and tried to use - new SimpleDataFormat("dd-MM-yyyy").format(new Date()); but not successful. Any help will be appreciated.
    Katherine

    Hi,
    you can display the date format in dd-mm-yy by using the below Java code.
    First import the bellow java classes.
    import java.util.Date;
    import java.text.SimpleDateFormat;
    //and add bellow code in run() function
         //************ Display Date and Time *************
         Date date_format=new Date();
         SimpleDateFormat dateFormat = new SimpleDateFormat("dd-mm-yyyy");// HH:mm:ss");
         String Exec_Time = dateFormat.format(date_format);
    //output statement
    info("Today's Date: "+Exec_Time);
    I can able to add the screenshot of this output here, so if you need any other information please write to me.
    Regards,
    MRSN

  • My mac disk is full and i cant transfer files from Mac to USB. saying the format is not good, how can i change the format and what happened to the files i have on USB?

    my mac disk is full and i cant transfer files from Mac to USB. saying the format is not good, how can i change the format and what happened to the files i have on USB?

    Once something similar happened to me. The external drives I had set up for FCP to use for some reason were not mounted, and FCP put all its render files on the main drive and I couldn't find them anywhere.
    Go to applications, and control-click (and hold down) on your FCP icon; you should get a pop up menu that says "show package contents". Select that, select the "contents" folder, then the "mac OS" folder. See if your quicktime file is in there, or if you've got render files in the "render" folder or audio render files in the "audio render" folder that don't belong there.
    That's where FCP sticks stuff when your documents FCP project folders are not available or when external drives you've selected aren't available.

  • I have used the resume tablet and put my resume into format but when emailing it, it will not open on windows. How can I change the format to where they will be able to open and view it?

    I have used the resume tablet and put my resume into format but when emailing it, it will not open on windows. How can I change the format to where they will be able to open and view it?

    I guess you mean one of the resume templates.
    What "format" have you saved your finished resume in?
    The only formats a Windows user will be able to open are .doc (Word), .pdf and rtf. The 1st 2 are usually the best.
    There is no Windows version of Pages.
    Peter

  • How can i change element's properties at specific time position?

    Hi, as the title describes, i want to change 'product_lg' position(left,top,width,height) at time position 'product_show' and 'product' automaticly, how can i do it with js?
    thanks!

    I known your solution, but i need to change it on trigger 'compositionReady' or 'compositionComplete', actually i want to init element's trigger effects at different time position automaticly.
    code as followed can change element's properties at current time, but it can't change element's properties at next coming trigger time:
    sym.$("Ellipse").css({'top':209, 'left':251, 'height':27, 'width':27});
    Thanks!

  • How can i change the Format of my DATE column?

    I need to change the date format for a whole column. At present i can do MM-DD-YYYY. I need to change this this to DD-MMM-YYYY.
    I know about the to_date function, i tried to apply it to change the format of my whole column by doing the following.....
    CREATE TABLE "IT220_DATEHOLIDAY"
    "DEPARTID" VarChar(2)NOT NULL ENABLE,
    "HOLCODE" VARCHAR2(2)NOT NULL ENABLE,
    "DEPARDATE" DATE,
    to_date('DATE','DD-MMM-YYYY'), <<<change DATE column to DD-MMM-YYYY
    CONSTRAINT "DATEHOLIDAY_PK" PRIMARY KEY ("DEPARTID") ENABLE
    ORA-00902: invalid datatype <<<<This was the error message i received.
    I am aware that the to_date function is supposed to be used to change strings into a certain format. I guess this means you cant do it with columns? Is there anyway i can format the whole column or do i have to do each string of data entered one by one?
    Thanks in advance!

    Hello Jay,
    I'm not sure you hit the right forum, as this doesn't seem to be a problem with APEX.
    Anyway:
    You can't use that function on a table like that, and as you already suggested, the to_date-function expects a string value.
    It seems you also have a misunderstanding of the basic datatypes in the database. DATE is such a datatype and is stored an internal format you don't need to care about. Each time your request the value, the database will give you a string representation according to either your locale or you give a certain formatting mask.
    The same applies to insert or update operations: you hand in either a variable of type DATE or use a function like to_date to create an "object" of type date.
    You may be interested in reading the documentation of the [url http://download.oracle.com/docs/cd/E11882_01/server.112/e16508/toc.htm]Oracle Database Concepts. The section concerning datatype DATE can be found here:
    http://download.oracle.com/docs/cd/E11882_01/server.112/e16508/tablecls.htm#CBBGJHJC
    An overview of formatting options can be found here:
    http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/sql_elements004.htm#SQLRF00212
    So to answer your question: You would format it as part of your insert operation, taking a string and convert it using to_date.
    -Udo

  • Can't Change Labels for Properties

    I Can't Change Labels for predefine Properties
    or Custom Properties.
    I had done it with this:
    http://help.sap.com/saphelp_erp2004/helpdata/en/65/6fc63ed4027f6be10000000a114084/frameset.htm
    I just followed what the help said.
    but i can't see any change for my label of Properties.
    I had done it as follow steps.Please help me to
    Check if i miss some steps!
    1,I creat .properties files
      mylabels.properties
       in this properties file  i creat a key
           modified=date
      mylabels_zh_CN.properties
        in this properties file  i creat a key
           modified=u66F4u65B0u65E5u671F
    2,I made a jar file use the two .properties files
      named mybunding.jar
    3,I copy this jar file to
    .../j2ee/cluster/server<n>/apps/sap.com/irj/servlet_jsp/irj/root/web-inf/portal/portalapps/com.sap.km.common.resourcebundle/lib
    4, Create a new metadata extension under Content Management -> Global Services -> Property Metadata -> Metadata Extensions.
      named it  my_metadatae_extension
       set  Bundle File=com.sap.km.common.resourcebundle.mybunding.mylabels
    5,restart the servlet engine,
    6 in the key for label of the properties
        i set modified the key i creat in step 1.
    when i display the properties it still didn,t display
    my created lable.
    How should i do? any step i miss? or any better solution
    for the lable?
    Please help me ,
    BestRegards
    Han

    Hi Han,
    here my corrections:
    1.
    I would use the filename "mylabels_cn.properties" and not "mylabels_zh_CN.properties"
    2.&3.
    This is the SP2 way for using the bundle files for properties. For NetWeaver you need to create a new PAR-file with the bundle file including the labels and translations as described <a href="http://help.sap.com/saphelp_nw04/helpdata/en/65/6fc63ed4027f6be10000000a114084/frameset.htm">here</a>.
    It's very easy if you use the example PAR file provided by SAP in SAP Note 817876, as mentioned in the referenced link (Prerequisites section).
    Read carefully the process in the link and try again. If you still experience problems, come back with the new detailed description.
    Hope this helps,
    Robert

  • How can i change date format in portal?

    how can i change the date format in the portal to dd-mmm-yyyy format 
    (e.g. 02-MAR-2007 or 02/ MAR/ 2007)
    i know that i have to change one of the properties listed in the path
    (systen administration->system config->Knowledge management-> content management->global services->property metadata->properties)
    but which property should i change and what should I modify it to?
    Nikhil

    Hi Nikhil,
    please have a look at SAP note <a href="https://service.sap.com/sap/support/notes/816761">816761</a> for solving this.
    Hope it helps,
    Robert

  • ICS 2: Can I change the format of the date displayed by Calendar Server from M/D/Y to D/M/Y using JavaScript?

    Can I change the order in which the month and day are displayed in Calendar
    Server using JavaScript? Specifically, I would like the date to be displayed
    in the format D/M/Y instead of M/D/Y.
    <P>
    Yes. You can change the format of the date by editing the JavaScript variable
    in the file <I>
    loadpoint</I>/CalendarServer/cal/uicust/en/main.html
    . The variable is located in the
    "Misc" section in the
    following line:<BR>
    <P>
    i18n['def date order'] = 'M/D/Y';
    <P>
    Edit the line as follows:<BR>
    <P>
    i18n['def date order'] = 'D/M/Y';

    Hello Mark,
    yes, it is possible. In Calendar Express under
    "Options | Settings -> Date"
    "Show brief dates in the following order: Date, Month, Year".
    BTW.: iCS 5.0 P4 is out since August, 2001. It's worth upgrading!
    Regards,
    Jakob.

  • How can i change music format to WAV prior to downloading?

    how can i change music to WAV prior to downloading?

    cg larry wrote:
    how can i change music to WAV prior to downloading?
    When you download music, it comes in the format that the store supplies it.
    WAV is a common format for the DJ market, as it is the best as input for pro audio editing.  Stores that cater to this market, and from which you can buy music in WAV format, include beatport.com and Juno Download
    Both of them also offer MP3/320 as an option, so make sure to select WAV.

  • How can we change page format from A6 to A4 in smart forms

    Hi,
    Currently smart form is printing output in A6 page.Now my customer wants in A4 page.How can we change the page format from A6 to A4.Now the output should print in A4 page instead of A6 page.
    I checked the page format in form attribtes it is DINA4.Do in need to change the page format here.
    Is there any settings for this.Plase advice.I appriciate your guidence in this regard.Thanks in advance

    Hi Vijay,
       As the form is formated to A4, now the one A4 sheet and take a print out as well take a print with A6 sheet check the difference.  If the data is not printed in right way then u need to do alignment.
    If it's printing in the same as it used to be, then check the settings in SPAD. 
    Br,
    Laxmi.Suryadevara

  • Where can I change the System properties permanently

    Instead of
    System.setProperty("name","new-value");
    to change the system properties in run-time.
    How can I change it in a config file? Where is it?
    Thx.

    Hai,
    We can't directly set the system properties values using config/properties file. But, if you wish to use <b>Spring </b> framework, there is an option to load system properties through a config file.
    Regards,
    Loga

  • In Numbers, how can you change the format of a cell on ipad mini?

    I used the paintbrush but the changes are not taking on the ipad mini but it keeps going back to the 'automatic' default.

    Hi Dempb,
    One of the ways this can happen is if the cells you are trying to format are the result of a formula or coming from elswhere in the table. For instance, if I have the formula SUM that is totaling a column formated "currency" I will not be able to change its format to "text".
    What do you want to do? there may be another way to accomplish it.
    Quinn

Maybe you are looking for

  • Just did the update and now home sharing isnt working. Im getting error -9808. Any ideas??

    I have no idea what is happening. My wifes library shows up on my account as does mine on hers and songs will play but we cant drag them into the library. When I o to turn on home sharing on my account it hits me with error code -9808.

  • ESata for T420s with docking station

    I notice the Mini Dock Plus Series 3 - 90W 433810U (as apposed to Mini Dock Series 3 - 90W 433710U) has a eSata port. Will this work with a T420s (which doesn't)? I'm planning to buy a docking station and use it to connect my 30" 2560x1600 display us

  • Scratch Disk & Windows 7 Default User

    Hello, I've been trying to set scratch disks for quite a few computers from the admin account to the secondary 1TB disk, for the admin acc this works perfectly fine. However, as soon as a new domain user logs in his / her scratch disk settings are ba

  • Third Party Spanning

    I have my iMac extended onto another monitor and I love it! But it's really annoying how you have to go all the way from the secondary monitor to the top corner of the primary monitor just to access a program's menu. Are there any work-arounds for th

  • Pen pressure turning on and off in CS5?

    Greetings! Long time photoshop user of 12 years, yet I've never used these forums. So. I run a Surface Pro 2 with Wacom drivers, however I've also run into this same problem on a hand built PC running windows 7 with an Intuos 4 medium. As I'm drawing