CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Remove field name and value from update

Print topic Send  topic

Author Message
beshoo

Posts: 68
Posted: 07/08/2009, 12:47 AM

Dear all.

Please kindly advice me in this small problem

i have a record on Update mode .

this record , has "username" ,"job" and "address" fields

i want to remove the address field from the update query , but not from the CCP file and not from the html code .

what the php code that i need to set to remove the "address" field from the update quarry

how come we can do this please advice!
_________________
beshoo Love PHP and CC 4.2
View profile  Send private message
jjrjr1


Posts: 942
Posted: 07/08/2009, 2:10 AM

Sure.

Just use custom update for the record component.

The custom update selection property is found in the property pane for the record component

Should be easy


_________________
John Real - More CodeCharge Studio Support at - http://CCSElite.com
View profile  Send private message
damian

Posts: 838
Posted: 07/08/2009, 2:14 AM

right click and change to hidden?

_________________
if you found this post useful take the time to help someone else.... :)
View profile  Send private message
jjrjr1


Posts: 942
Posted: 07/08/2009, 2:30 AM

Hmmm

That is also an interesting way to accomplish this need if you just do not want the value to change in your table..

1. If you use cuctom update. the field will display, you will be able to change it on the update screen. But the value will not be updated in the table.

2. if you set the format property type for the control to hidden (right Click & Change to hidden) the value will be in your html but not displayed on your update screen. The value will be updated in the table but not changed.

3. In the format property for the control set to read only for text fields, disabled for list boxes, radio buttons etc. This will display on the update screen the value of the control but the client will not be able to change it. The table will get updated by the query but not changed.

Guess it depends on your requirements for this.


_________________
John Real - More CodeCharge Studio Support at - http://CCSElite.com
View profile  Send private message
beshoo

Posts: 68
Posted: 07/08/2009, 2:37 AM

This is the solution that i am looking for :

unset($addusers->DataSource->UpdateFields[Address]);

this will set in "Before Execute Update" event .

thank you for your help .
_________________
beshoo Love PHP and CC 4.2
View profile  Send private message
jjrjr1


Posts: 942
Posted: 07/08/2009, 3:04 AM

Cool

I usually try and stay away from as much custom code as possible particularly if CCS has a built in method to do what I want.

If this is really what you want to do, I would really suggest looking at custom update properties and avoid custom code.

But there are always many ways to skin a cat. lol


_________________
John Real - More CodeCharge Studio Support at - http://CCSElite.com
View profile  Send private message
damian

Posts: 838
Posted: 07/08/2009, 4:20 AM

what are you trying to do? why do you want the field not to be changed but still to be there?
change it to a label or hidden retains the field without modifying it... is that what you are trying to do?
_________________
if you found this post useful take the time to help someone else.... :)
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.

PHP Reports

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

Home   |    Search   |    Members   |    Register   |    Login


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