Hello, I'm wrting some code as part of our custom module and I loop through arrays of Contact & Account objects.
I'm printing out a field from the contact object and it works fine for the first 100 lines of code but then it just stop printing the values.
$contacts = $loan->get_contacts();
for($j=0;$j<sizeof($contacts);$j++){
$rowsOut[$i] = "04A" . str_pad(Util:arseSSN($contacts[$j]->ssn_c), 9, " ", STR_PAD_RIGHT) . Util:
rintSpaces(2)
There is value for the ssn_c yet it prints blank spaces. I used the same code about 100 lines up and the ssn_c prints.
There is no where in the code that the value gets set to blank so I don't understand whats going on.
I also have an issue where I load a blank Lead
$lead = new Lead();
I then set a bunch of variables but I leave the ID blank. According to the code since the ID is blank, it will insert a new Lead and I should be able to get the new id by calling $lead->id after I call save.
This works about 9$% of the time, the other 5% MOST of the values get inserted except it dies half way and returns 0 instead of the new ID.
We're on sugar 4.2.0d


LinkBack URL
About LinkBacks
arseSSN($contacts[$j]->ssn_c), 9, " ", STR_PAD_RIGHT) . Util:



Reply With Quote
Bookmarks