private void LoadFile(string filename)
 {
     try
     {
         var temp = new Memory();
         temp.Load(filename, out var start, out _);
         Text   = $@"C64 Memory Visualizer - {filename}";
         Memory = temp;
         DisplayPointer.FromInt(start.Value);
         DisassemblyStartAddress.FromInt(start.Value);
         DisplayMode = DisplayMode.HexRaw;
         if (Memory != null)
         {
             MemOverview = MemOverview.Create(
                 Memory,
                 Height,
                 DisplayMode == DisplayMode.Disassembly ? DisassemblyStartAddress.Value : 0);
         }
         RenderScreen();
     }
     catch
     {
         MessageBox.Show($@"The file ""{filename}"" could not be loaded.",
                         Text,
                         MessageBoxButtons.OK,
                         MessageBoxIcon.Error);
     }
 }
 private bool SetDisassemblyStartAddress()
 {
     using (var x = new PrgStartAddressDialog())
     {
         x.StartAddress = DisassemblyStartAddress.Value;
         if (x.ShowDialog(this) != DialogResult.OK)
         {
             return(false);
         }
         DisassemblyStartAddress.FromInt(x.StartAddress);
         DisassemblyStepSize.Clear();
         DisplayPointer.FromInt(x.StartAddress);
         RenderScreen();
         return(true);
     }
 }