例: AdjustSecond method

  1. 次のスクリプトは、NotesDateTime オブジェクトの値に 20 秒を加算します。その結果、このオブジェクトの値は 04/16/96 05:36:20 PM になります。
    Dim dateTime As New NotesDateTime( "04/16/96 05:36 PM" )
    Call dateTime.AdjustSecond( 20 )
  2. 次のスクリプトは、NotesDateTime オブジェクトの値から 20 秒を減算します。その結果、このオブジェクトの値は 04/16/96 05:35:40 PM になります。
    Dim dateTime As New NotesDateTime( "04/16/96 05:36 PM" )
    Call dateTime.AdjustSecond( -20 )
  3. 次のスクリプトは、今日の日付が設定される NotesDateTime オブジェクトを作成し、作成したオブジェクトの値に 50 秒を加算しようとします。しかし、dateTime には時刻の部分がないため、この AdjustSecond メソッドは無効です。
    Dim dateTime As New NotesDateTime( "Today" )
    Call dateTime.AdjustSecond( 50 )