Nel

Nel

  • NA
  • 716
  • 1.1m

Return the value of a fild as a checkbox

Aug 15 2011 8:29 AM
Hello,

I have a field in the database which is string and I take only the first character of it for checking. Can anybody help me: how can I retrieve the value as a checkbox, for example to present it as checked if it has E as a first letter of the string, or not checked otherwise when displaying the data on the form?

I tried this when configuring the oledbdataadapter:
SELECT     brdok, vp, valuta, valuta_kurs, imeprezime, iznos, iznosden, datum, br_kas_izvod, br_pat_smetka, tip
FROM         blagajna_jspturs
WHERE     (brdok = ?)
if (select valuta from blagajna_jspturs)="E"
radiobutton1.checked=true;
else
radiobutton2.checked=true;

but it doesn't work.

Thanks.

Answers (1)