Figured how to accomplish this. Posting in the event anyone else has a need to alter the pickers at run time.
Picker1.Open
[code] dim tx0() as text
tx0() = Array("", "alcohol gram","carb gram","fat gram","kilocalorie", "kilojoule", "protein gram")
me.AddColumn(tx0)[/code]
Picker2.Open
[code]dim tx0() as text
tx0() = Array("", “kilocalorie”, “kilojoule”)
me.AddColumn(tx0)
[/code]
SwapButton.Action
[code] dtPicker1.RemoveColumn(0)
dtPicker2.RemoveColumn(0)
dim txPick1() as text
dim txPick2() as text
if swapInt = 0 then
txPick1() = Array("", “kilocalorie”, “kilojoule”)
txPick2() = Array("", “alcohol gram”,“carb gram”,“fat gram”,“kilocalorie”, “kilojoule”, “protein gram”)
dtPicker1.AddColumn(txPick1)
dtPicker2.AddColumn(txPick2)
dtPicker1.SelectRow(Picker2Row, Picker2Column)
dtPicker2.SelectRow(Picker1Row, Picker1Column)
Picker1Text = dtPicker1.GetText(Picker2Row, Picker2Column)
Picker2Text = dtPicker2.GetText(Picker1Row, Picker1Column)
swapInt = 1
elseif swapInt = 1 then
txPick1() = Array("", “alcohol gram”,“carb gram”,“fat gram”,“kilocalorie”, “kilojoule”, “protein gram”)
txPick2() = Array("", “kilocalorie”, “kilojoule”)
dtPicker1.AddColumn(txPick1)
dtPicker2.AddColumn(txPick2)
dtPicker1.SelectRow(Picker1Row, Picker1Column)
dtPicker2.SelectRow(Picker2Row, Picker2Column)
Picker1Text = dtPicker1.GetText(Picker1Row, Picker1Column)
Picker2Text = dtPicker2.GetText(Picker2Row, Picker2Column)
swapInt = 0
end if
[/code]