Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Trying to Update Item Base price in IC

Status
Not open for further replies.

NewCCTech

Technical User
Feb 18, 2010
65
CA
Hi All,

I am trying to update Item base price in IC, but not sure which view should I update? Item Pricing IC1660 or Update Item Pricing IC1640?

Here is my criteria---Update item Base price, if it is greater than $200, then discount would be 30; if it is less than $200, then discount would be 44.

Your great help would be Appreciated!

 
Record a macro of you updating the price on a couple of items. Change the base price when you're recording the macro and change it back. That way the macro will record the field name of the view field that you're looking for.
 
Thanks DjangMan!

I did the macro and was able to update the UNITPRICE in ICPRICP, now I got another question----which date should I use to update field LASTPRICDT? the AUDTDATE before my update or the current AUDTDATE (means NOW)?

Happy New Year to you and everyone in this Forum too!


 
LASTPRICDT is updated automatically by the view, you're not supposed to change it.
 
Hi tuba2007,

Yes, you are right!

Thanks and Happy New Year!
 
Hi,

I got problem when I was testing my program.

In the following code lines, when sTemp = 'YF1Z17906AB' or '8663129600' and run my program, then evrything is working very well, but when I put them as two records in the input file, whichever is the first gets running through and update the price, but for the second one, temp (=ICPRIC_T1header.Fetch();) would be FALSE. I could not figure it out why, so could anyone help me out here?

Your help would be greatly appreciated.

ICPRIC_T1header.Browse("(PRICELIST =\"MAIN\")AND (CURRENCY = \"CAD\")AND (PRICEBASE = \"1\") AND (ITEMNO = \"" + sTemp + "\")", true);

temp = ICPRIC_T1header.Fetch();
 
What is the actual browse statement that is being passed to the view? Assign
Code:
"(PRICELIST =\"MAIN\")AND (CURRENCY = \"CAD\")AND (PRICEBASE = \"1\") AND (ITEMNO = \"" + sTemp + "\")"
to a variable and show us what it holds.
 
Fetch is browsing forward only, so if you got item YF1Z17906AB then it will not find 8663129600 since it needs to go backwards for that.
Do .Init on the header before the .Fetch and it will find the record.
 
Thanks Ettienne and DjangMan!

It works when I put .Init() before .Fetch()

Happy New Year to you all!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top