Page tree
Skip to end of metadata
Go to start of metadata

This function is used to retrieve persons and/or companies entries registered in Iceland

Parameters

Used to call the function

  1. options  - TRegistrationGetOptions

Returns

Returns the following

 

This function only returns data if a contract with Þjóðskrá and/or RSK and a contract with dkVistun for update services for the information

Possible values for options.ExtraProperties

  • FamilyNumber
  • SortedName
  • County
  • Street
  • House
  • Floor
  • Gender
  • FamilyState
  • ProhibitCode
  • Citizenship
  • PlaceOfBirth
  • SpousePersIdNumber
  • CurrentState
  • ChurchCode
  • ProfessionNumber
  • TypeOfProfession

 

 

Example .NET C# - Full Sync
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
using WindowsFormsApplication3.dkWS;
namespace WindowsFormsApplication3
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }
        public void SyncNation()
        {
            IItemServiceservice service = new IItemServiceservice()
            {
                BasicSecurityValue = new BasicSecurity() { Username = "authorizeduser", Password = "password" },                
            };
            var dt = new DateTime(1899, 12, 30);
            List<TRegistrationEntry> list = new List<TRegistrationEntry>();
            bool doFetch = true;
            do
            {
                var entries = service.GetRegistrations(new dkWS.TRegistrationGetOptions() { Modified = dt, MaxEntries = 400 });
                list.AddRange(entries);
                if (entries.Count() == 0)
                {
                    doFetch = false;
                }
                else
                {
                    dt = entries[entries.Length - 1].Modified.AddMilliseconds(1);
                }
            } while (doFetch);
        }
    }
}

To get only changes after a full sync just pass the last Modified of the last entry fetched