Invoice_FindByOtherReference

Forum for .PHP developers using the E-conomic API.
Exchange your ideas, tip and tricks using the API.
Best Practices

Invoice_FindByOtherReference

Postby koldstar » Sat Aug 14, 2010 4:28 pm

Hi

Can anyone tell me what I'm doing wrong here? I'm trying to use FindByOtherReference:

$my = $client->Invoice_FindByOtherReference(array('otherReference' => '356'))->Invoice_FindByOtherReferenceResult;
print_r($my) ;

It returns an empty object each time? But if I try to do the same exercise with Debtors it works fine!

$myDebtor = $client->Debtor_FindByNumber(array('number' => 104))->Debtor_FindByNumberResult;
print_r($myDebtor) ;

I have also tried to get all invoices to control it, but it returns nothing to:

$my2 = $client->Invoice_GetAll()->Invoice_GetAllReferenceResult;
print_r($my2) ;
-
koldstar
 
Posts: 2
Joined: Wed Dec 02, 2009 5:42 pm

Re: Invoice_FindByOtherReference

Postby ParisNakitaKejser » Wed Nov 17, 2010 3:22 am

Can i plase know what your point is?

are you crating a ordre after that upgradet to invoice or?
Paris Nakita Kejser
CEO / Software Developer

Image

Web: http://sharkcoders.com
Phone: +45 3027 9555
Mail: info@sharkcoders.com
-
ParisNakitaKejser
 
Posts: 6
Joined: Wed Nov 17, 2010 3:06 am

Re: Invoice_FindByOtherReference

Postby Madman » Wed Nov 17, 2010 9:06 pm

Code works fine. Do you have a booked invoice that has 365 as other ref?
Invoice searches booked invoices.
If you want to find a invoice that is active (Under the Invoices menu in the webinterface), you have to use CurrentInvoice.
And the refernce must be exact, It won't find reference that is 3654 or 3651, it will only find reference that is 365
-
Madman
 
Posts: 17
Joined: Thu Jun 24, 2010 9:04 am


Return to PHP