示例#1
0
		/////////////////////////////////////////////////////////////////////////////
		public bool Open(string filename)
		{
			Close();
			if (m_Document != null)
				return false;

			bool fakeUserData = (filename == null);
			if (fakeUserData)
			{
				List<Account> accounts = WebResources.Accounts;
				if (accounts == null)
					return false;

				m_Document = new Document(this);

				// Load the account table
				for (int i = 0; i < accounts.Count; i++)
					m_Document.AddAccount(accounts[i]);
			}
			else
				m_Document = Document.Open(filename);

			m_Document.DocHolder = this;
			JulianDay lStartDate = new JulianDay(1, 1, 1955);
			JulianDay lEndDate = new JulianDay(12, 31, 1955 + 120);
			JulianDay lDate = DateTime.Today.ToJulian();
			Run(lStartDate, lEndDate, lDate);

			SendChangeEvent();
			return true;
		}
示例#2
0
		/////////////////////////////////////////////////////////////////////////////
		private void Draw(Document document)
		{
			if (document == null)
				return;

			List<Account> accounts = document.AccountList;
		}
示例#3
0
		/////////////////////////////////////////////////////////////////////////////
		// Method used to catch the document's ChangeEvent
		public abstract void DocumentChange(Document document, EventArgs e);
示例#4
0
		/////////////////////////////////////////////////////////////////////////////
		// Method used to catch the document's CloseEvent
		public abstract void DocumentClose(Document document, EventArgs e);
示例#5
0
		/////////////////////////////////////////////////////////////////////////////
		public void Close()
		{
			if (m_Document != null)
				SendCloseEvent();
			m_Document = null;
		}
示例#6
0
		/////////////////////////////////////////////////////////////////////////////
		public DocumentHolder()
		{
			m_Document = null;
		}
示例#7
0
		/////////////////////////////////////////////////////////////////////////////
		public bool Run(Document document, JulianDay lDate, JulianDay lParentStartDate, JulianDay lParentEndDate)
		{
			return false;
		}
示例#8
0
		public override void DocumentChange(Document document, EventArgs e)
		{
		}
示例#9
0
		public override void DocumentClose(Document document, EventArgs e)
		{
		}
示例#10
0
		/////////////////////////////////////////////////////////////////////////////
		public bool Run(Document document, JulianDay lDate)
		{
			return false;
		}
示例#11
0
		/////////////////////////////////////////////////////////////////////////////
		// Method used to catch the document's CloseEvent
		public override void DocumentClose(Document document, EventArgs e)
		{
//j			m_AccountsTextBlock.Text = "";
		}