Now that I have some code working that is saving the backcolor of a textfield, how do I also save text to the same textfield as well, this is the code I am using to save the backcolor.
This code is in the change event of the combobox :
[code] Dim d As new dictionary
d.value(“Mens”) = &cFF00FF 'RGB(255,0,255)
Dim myColor As string = combobox1.Text
if d.hasKey(myColor) Then
test1.backcolor = d.value(myColor)
test2.backcolor = d.value(myColor)
end if[/code]
This is the method I came up with to save the backcolor:
[code]dim mycolor as string
mycolor = Str(Test1.backcolor)
dim dr as New DatabaseRecord
dim rs as RecordSet
if golfer <> nil then
rs = golfer.SQLSelect("select * from test where PK = "+ str(testpk))
end if
dr.column(“test1”) = (mycolor)
app.golfer.InsertRecord “test”, dr
app.golfer.commit
msgbox"New Record Added"[/code]
I have tried a couple of things but it always saves the the text to a new row in the database.