Canvas Scaler: Alternate Hack?

Hi there,
I am creating a UI for iOS. My issue is resolution sizes and the Unity UI, as it relates to scaling and positioning, depending on resolution.

My approach to deal with this is to monitor screen size and orientation and adjust accordingly, via script. What I am wondering is, is this ideal? Is there a native way in Unity to account for this (Canvas Scaler doesnt seen to be doing what I want).

I have made this script, as you can see it accounts for each resolution and sets the premade game object (host of UI Buttons, set in size and position), to be SetActive(true). This will work, but I am wondering if there is an eaiser way.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class UI_ResolutionMng : MonoBehaviour {




 public GameObject[] Home_Landscape;
 public GameObject[] Home_Portrait;
 public GameObject[] Store_Landscape;
 public GameObject[] Store_Portrait;
 public GameObject[] Game_Landscape;
 public GameObject[] Game_Portrait;

 bool isActive;

 float last_h;
 float crnt_h;
 float h;
 float w;
 int device;
 string scene;

 GameObject gm_crntBtns;


 void Awake(){
 DontDestroyOnLoad(gameObject);
 }
 
 //Usethisfor initialization
 void Start () {

 Scene currentScene = SceneManager.GetActiveScene ();
 //Retrievethenameofthisscene.
 string sceneName = currentScene.name;

 print(sceneName);

 }

 void OnEnable(){

 print("ENABLED");
 isActive = true;
 }
 void OnDisable(){
 print("DISABLED");
 isActive = false;


 }



 void Update(){

 
 if(isActive){

 ///get scene

 if(Home_Mng.instance != null){
 scene = "HOME";
 }
 if(StoreMng.instance != null){
 scene = "STORE";
 }
 if(ERS_Mng.instance != null){
 scene = "GAME";
 } 


 //get resolution

 w = Screen.width;
 h = Screen.height;
 crnt_h = h;

 //ifresolutionhcrnt!=hlast,meanswehaveswitchedorientaion
 if(crnt_h != last_h){



 //iPhone
 //---------------
 //iPhone 7
 if(w == 750 && h == 1334){
 ///Portrait
 device = 0;
 }
 if(w == 1334 && h == 750){
 ///Lanscape
 device = 0;
 }
 //---
 //iPhone7 Plus
 if(w == 1242 && h == 2208){
 ///Portrait
 device = 1;
 }
 if(w == 2208 && h == 1242){
 ///Lanscape
 device = 1;
 }
 //---
 //iPhone 5
 if(w == 640 && h == 1136){
 ///Portrait
 device = 2;
 }
 if(w == 1136 && h == 640){
 ///Landscape
 device = 2;
 }
 //---
 //iPhone 4
 if(w == 640 && h == 960){
 ///Portrait
 device = 3;
 }
 if(w == 960 && h == 640){
 ///Lanscape
 device = 3;
 }




 //iPad
 //---------------
 //iPad
 if(w == 1536 && h == 2048){
 ///Portrait
 device = 4;
 }
 if(w == 2048 && h == 536){
 ///Lanscape
 device = 4;
 }
 //---------------
 //iPad Mini
 if(w == 768 && h == 1024){
 ///Portrait
 device = 5;
 }
 if(w == 1024 && h == 768){
 ///Lanscape
 device = 5;
 }


 setBtn();
 }

 last_h = crnt_h;
 }
 }
 

 void setBtn(){
 print("SETBTN" + Time.time);

 if(gm_crntBtns != null){
 gm_crntBtns.SetActive(false);
 }

 if(w > h){
 //LANDSCAPE
 if(scene == "HOME"){
 Home_Landscape[device].SetActive(true);
 gm_crntBtns = Home_Landscape[device];
 }
 if(scene == "STORE"){
 Store_Landscape[device].SetActive(true);
 gm_crntBtns = Store_Landscape[device];
 }
 if(scene == "GAME"){
 Game_Landscape[device].SetActive(true);
 gm_crntBtns = Game_Landscape[device];
 }
 }
 else{
 //PORTRAIT
 if(scene == "HOME"){
 Home_Portrait[device].SetActive(true);
 gm_crntBtns = Home_Portrait[device];
 }
 if(scene == "STORE"){
 Store_Portrait[device].SetActive(true);
 gm_crntBtns = Store_Portrait[device];
 }
 if(scene == "GAME"){
 Game_Portrait[device].SetActive(true);
 gm_crntBtns = Game_Portrait[device];
 }
 }


 }

}