Quantcast
Channel: Web Forms
Viewing all articles
Browse latest Browse all 23244

entity command

$
0
0

hi 

i want to use entity but i cant find a way to do that so i used entity command

i  need to get field name from user with (dropdownlist1) and value with (tbnumber.txt) then update that field from my db plus new value

my code is this

=====================

1-Dim userin_name As String = "username"
2-Dim codein As String = ""
3-db.sellitem(userin_name, DropDownList1.SelectedValue, tbfee.Text, tbnumber.Text, selected.Item(0).x_y)
4-Dim defvalu = db.ExecuteStoreCommand("select " & DropDownList1.SelectedValue & " from Equipment where user_name='username'")
5-defvalu -= tbnumber.Text
6-db.ExecuteStoreCommand("update Equipment set " & DropDownList1.SelectedValue & "=" & defvalu + tbnumber.Text & " where user_name='" & userin_name & "'")

==========

but in line 4 i allways get -1

thank you

if some ono have better idea please tell me


Viewing all articles
Browse latest Browse all 23244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>