Keyboard input for multiple variables

I have tried searching what’s currently on the forums and am yet to get an answer that I understand, I want to be able to keyboard input text for multiple variables. For example if I had variables A, B & C I would like the keyboard to show, type the text for A, press enter and have the keyboard show for B and enter text and the same for C and have the text stored in each variable for me to then display on screen. If anyone could help that would be greatly appreciated.

@TheHam Here’s something that might work.

function setup()
    rectMode(CENTER)
    showKeyboard()
    str=""
    val=1
    tab={"A","B","C"}
    tab1={}
end

function draw()
    background(80,80,80)  
    fill(0)
    noStroke()
    rect(WIDTH/2+10,HEIGHT/2+190,200,50)
    rect(WIDTH/2+10,HEIGHT/2+90,200,50)
    fill(255)
    stroke(255,0,0)
    strokeWidth(5)
    rect(WIDTH/2,HEIGHT/2+200,200,50)    
    fill(150,150,150)
    stroke(255)
    strokeWidth(5)    
    rect(WIDTH/2,HEIGHT/2+100,200,50)
    fill(255,0,0)    
    text("Type the text for "..tab[val],WIDTH/2,HEIGHT/2+200)   
    str=keyboardBuffer()
    if rtn then
        tab1[val]=string.sub(str,1,string.len(str)-1)
        rtn=false
        hideKeyboard()
        showKeyboard()
        val=val+1
        if val>#tab then
            val=1
        end
    end    
    fill(255)
    text(str,WIDTH/2,HEIGHT/2+100) 
    for z=1,#tab1 do
        text(tab[z].."  =  "..tab1[z],100,HEIGHT-z*20)
    end
end

function keyboard(k)
    if k==RETURN then
        rtn=true
    end 
end

function touched(t)
    if not isKeyboardShowing() then
        showKeyboard()
    end
end