Forums: [SOLVED] AfterEdit() Values Aren't Correct, Can't Run Logic - Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • This topic is locked

[SOLVED] AfterEdit() Values Aren't Correct, Can't Run Logic values["MyField"] apparently doesn't return the right valu Rate Topic: -----

#1 User is offline   RockyMtnHi 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 34
  • Joined: 04-December 09

Posted 12 July 2018 - 02:26 AM

When I run code in the AfterEdit() function of the After Record updated event I echo the following values:
TaskId: v
NewDate: v
OrigDate: o

TaskId is an integer and the other two are dates, but obviously that isn't whats coming out. Here is the code:

echo "TaskId: ". values["TaskId"] ."<br />";
echo "NewDate: ". values["DateCompleted"] ."<br />";
echo "OrigDate: ". oldvalues["DateCompleted"] ."<br />";

When I use these values in the logic of the event I'm writing it obviously doesn't work.

Any ideas? I don't know what to try here. I thought of formatting the value in some way, but I felt it was grasping for straws or arm waving.

Thanks for the help.
0

#2 User is offline   John 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 537
  • Joined: 02-December 05

Posted 12 July 2018 - 03:27 AM

View PostRockyMtnHi, on 11 July 2018 - 10:26 PM, said:

When I run code in the AfterEdit() function of the After Record updated event I echo the following values:
TaskId: v
NewDate: v
OrigDate: o

TaskId is an integer and the other two are dates, but obviously that isn't whats coming out. Here is the code:

echo "TaskId: ". values["TaskId"] ."<br />";
echo "NewDate: ". values["DateCompleted"] ."<br />";
echo "OrigDate: ". oldvalues["DateCompleted"] ."<br />";

When I use these values in the logic of the event I'm writing it obviously doesn't work.

Any ideas? I don't know what to try here. I thought of formatting the value in some way, but I felt it was grasping for straws or arm waving.

Thanks for the help.


Don't forget the $ before values.


echo "TaskId: ". $values["TaskId"] ."<br />";
echo "NewDate: ". $values["DateCompleted"] ."<br />";
echo "OrigDate: ". $oldvalues["DateCompleted"] ."<br />";


0

#3 User is offline   RockyMtnHi 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 34
  • Joined: 04-December 09

Posted 12 July 2018 - 03:57 PM

Don't forget the $ before values.


echo "TaskId: ". $values["TaskId"] ."<br />";
echo "NewDate: ". $values["DateCompleted"] ."<br />";
echo "OrigDate: ". $oldvalues["DateCompleted"] ."<br />";

-------

Ha ha ha. Sometimes you just look at it too long. Thanks John.
0

Page 1 of 1
  • You cannot start a new topic
  • This topic is locked