Ui text to string ?

InputField x;
string y;

    y = x.text;

?
Sorry My English is Bad

No need to Convert InputField to String - Because already InputField in string format.

String to Int :- int.Parse(varibleOfString);

Int to String :- varibleOfInt.ToString();

using UnityEngine;
    using System.Collections;
    using UnityEngine.UI;
    public class TestCode : MonoBehaviour {
    	public InputField x;
    	string y;
    	void Update()
    	{
    		y = x.text;
    		Debug.Log (y);
    	}
    
    }