Exemple #1
0
        protected override async Task OnInitializedAsync()
        {
            // Create a timer with a two second interval.
            Timer aTimer = new System.Timers.Timer(5000);

            // Hook up the Elapsed event for the timer.
            //aTimer.Elapsed += OnTimedEvent;
            aTimer.AutoReset = true;
            aTimer.Enabled   = true;

            PageHeaderText = "Station Kantor Pusat";
            StationUid     = "2000000000014";

            StationXs = (await StationXService.GetStationXs()).ToList();

            await LoadData();
        }
Exemple #2
0
        //private static void OnTimedEvent(Object source, ElapsedEventArgs e)
        //{
        //    Console.WriteLine("The Elapsed event was raised at {0:HH:mm:ss.fff}", e.SignalTime);
        //    InvokeAsync(gridDT.Reload());
        //}

        protected async Task LoadData()
        {
            StationXs = (await StationXService.GetStationXs()).ToList();
            await InvokeAsync(StateHasChanged);
        }