: : : : : hi,
: : : : :
: : : : : my problem is:
: : : : : i have a field custID in Orders table, which must be in Customers table.
: : : : : what i wont is: when i fill the cusID field-pass the correct cusName, after i move to another field on the Orders form.
: : : : :
: : : : : thnk you all
: : : : : amra.
: : : : :
: : : : : p.s. the connection to recordset in Customers table is ok.
: : : : : i think the main problem is where do i put my select? is there any event like After update field... or something......
: : : : :
: : : :
: : : :
: : : : Didnt really get what you want,you also want to find customer name corresponsding to the custid??
: : : :
: : : : Can you explain a bit more?
: : : :
: : : you are right. i want to find customer name corresponsding to the custid. it is a simple select statemant, but i cannot find the right place for it.
: : : i think i have two problems: the first is that i have to do select before i actialy get to the database open,
: :
you cannot do a select without a database connection
: : the second is that i can not assign any values after filling specific field, and before submit button.
: : : i fond something in VBScript like, AfterUpdateField, WillChangeField... but it does not work, or i dont use it as i should
: : :
: :
: :
If you post some code maybe we will have a try at it..
: :
: :
: i think that connection is ok, it actually works ok, because i get the value i need in session variable... here is the code i wrote
:
: dim ud_MySQL
: dim ud_oRSTemp
: set ud_oRSTemp=Server.CreateObject("ADODB.Recordset")
: ud_MySQL="SELECT dbo.AARTIKLI.NAZIV FROM dbo.AARTIKLI WHERE dbo.AARTIKLI.ARTIKAL =" & CSTR(oRSNARSTAVKE.Fields("ARTIKAL").Value)
:
: ud_oRSTem.Open ud_MSQL, objCN, adOpenStatic, adLockReadOnly, adCmdUnspecified
:
:
:
: ud_art= ud_oRSTem.Fields("NAZIV").Value
:
: ud_oRSTem.Close
: SET ud_oRSTem=NOTHING
:
:
: this code works ok, i get value i need but after submit button.
In ASP, you will only get the value after a submit,because it requires a server action for stuff like DB Access.
: is there any va to track focus, and mybe put this code after field has lost focus?
Losing focus is a client side action.You could force a submit using javascript,like
<input type="text" name="txtsomething" onBlur="this.form.submit();">
But thats still a submit...
i have no idea...
: points where i can actally put this code in tool i have to use are:
: Before and after merge call, and on processor side: before open, after open, before and after update, and before and after close.
: