Sha256: af9803860c68e14ed26aebcfc643817fdb692c88030a88fc5212b1cce42830c0
Contents?: true
Size: 1.52 KB
Versions: 1
Compression:
Stored size: 1.52 KB
Contents
module Asposetasksjava module FiscalYearProperties def initialize() # Reading Fiscal Year Properties get_fiscal_year_properties() # Writing Fiscal Year Properties set_fiscal_year_properties() end def get_fiscal_year_properties() data_dir = File.dirname(File.dirname(File.dirname(File.dirname(__FILE__)))) + '/data/' # Instantiate project object project = Rjb::import('com.aspose.tasks.Project').new(data_dir + 'test_tasks.mpp') prj = Rjb::import('com.aspose.tasks.Prj') # Display fiscal year properties puts "Fiscal Year Start Date : " + project.get(prj.FY_START_DATE).toString() puts "Fiscal Year Numbering : " + project.get(prj.FISCAL_YEAR_START).toString() end def set_fiscal_year_properties() data_dir = File.dirname(File.dirname(File.dirname(File.dirname(__FILE__)))) + '/data/' # Instantiate project object project = Rjb::import('com.aspose.tasks.Project').new prj = Rjb::import('com.aspose.tasks.Prj') # Set fiscal year properties project.set(prj.FY_START_DATE, Rjb::import('com.aspose.tasks.Month').July) project.set(prj.FISCAL_YEAR_START, Rjb::import('com.aspose.tasks.NullableBool').new(true)) project.save(data_dir + "fiscal_year_properties.xml", Rjb::import('com.aspose.tasks.SaveFileFormat').XML) puts "Set fiscal year properties, please check the output file." end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
asposetasksjava-0.0.1 | lib/asposetasksjava/Projects/fiscalyearproperties.rb |