CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> ASP

 Problems updating second table from editable grid

Print topic Send  topic

Author Message
sappie

Posts: 13
Posted: 10/16/2007, 3:44 AM

I have an editable grid (called "RFC_Transport") which updates a certain table. This works fine.
Now I want a second table to be updated:
In the editable grid I have the elements "RFC_Id" (link) which is the key field for the second table. Further the grid contains the radiobutton "TP_MD3_RC".
If this radiobutton has a certain value ( <> 999) I want the second table to be updated.

To achieve this I used the example of Nicole (http://forums.codecharge.com/posts.php?post_id=60507) in the 'BeforeExecuteUpdate':

----------------------

Dim SQL
Dim Connection
Dim ErrorMessage
Dim RFCID
Dim MD3RC

Dim j
for j = 1 to RFC_Transport.PageSize + RFC_Transport.EmptyRows
RFCID = CCGetParam("RFC_Id_" & Cstr(j), Empty)
MD3RC = CCGetParam("TP_MD3_RC_" & Cstr(j), Empty)

If MD3RC <> 999 Then

Set Connection = New clsDBRFC
Connection.Open
SQL ="UPDATE RFC SET RFC_Status=98 where RFC_Id=RFCID"
Connection.Execute(SQL)
Connection.Close
Set Connection = Nothing

End If
next
----------------------

Unfortunately the update op the second table (RFC) doesn't happen.
Seems to me the control values of the editable grid aren't fetched. Because if I replace them ('MD3RC' or 'RFCID') with fixed values the second table is updated.

Can someone please help me out? I've searched for answers on the forum but didn't succeed in finding the answer.
What I'm I doing wrong? Is there an error in the coding or is it in the wrong place?

Kind regards,
Harold
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.