Export to Excel

nav_126nav_126 Member Posts: 77
Dear all,

I have a problem regarding export to excel using excel buffer concept in Navision 4.0 SP3.

When we export to excel, we call the function createsheet and enter sheet name.

But i want system to enter data directly to Sheet1 of excel sheet. is there any way to do this?

Regards
Navision Developer

Comments

  • BeckaBecka Member Posts: 178
    Hi :)
    You can use Automation and create sheet through code... ( sounds like an option )
    good luck
    MCSD
    Attain Navision
  • nav_126nav_126 Member Posts: 77
    which Automation i should use? any idea?

    Its urgent please,



    Regards
    Navision Developer
  • sfosfo Member Posts: 12
    Hello,

    The Automation is Microsoft Excel 11.0 Object Library.Application (12 for Office 2007 I guess)

    Sample code for creating the XLS and selecting the Active sheet:
    CREATE(xlApp);
    xlBooks := xlApp.Workbooks;
    xlBooks.Add;
    xlBook := xlApp.ActiveWorkbook;
    xlSheet := xlApp.ActiveSheet;  
    

    Hope it helps.
Sign In or Register to comment.