Baanboard.com

Baanboard.com (http://www.baanboard.com/baanboard/index.php)
-   Manufacturing & Supply Chain (http://www.baanboard.com/baanboard/forumdisplay.php?f=7)
-   -   To use Print Material Shortage (http://www.baanboard.com/baanboard/showthread.php?t=60117)

quelle 24th February 2011 15:52

To use Print Material Shortage
 
Hi all

What is the best way to use Print Material Shortage session?
eg :
The inventory for material is 30, then 3 Production Orders need this material , each production order required 25 which has different start date just different time.

If I Print Material Shortage for just 1 Production Order it will said no Shortage.

So is this the best way to run this session for all production order which will be start in same date ?
Because thats not possible to print it for each production order.

joemon 4th March 2011 11:25

Hi quelle,

Thorugh Stdndard, you can do one thing , for the Specific item hard allocate to the inventory for the specific Production . then system show you the actual shortage.


Thanks & Regards

Joemon VJ

Aryaraj 26th September 2015 09:13

Materia shortage
 
Dear Sir,

In FP7 if row material is not available still system allows to complete the operation. Is there any way to resolve this issue?

Regards
Aarya

erplncons 28th September 2015 06:47

That is a flexibility in the system. It would allow you to complete the order, but not allow you to close it unless all the material is issued.

Aryaraj 28th September 2015 08:33

Dear Sir,

If we want that system should not allow for report operation completed still the row material is not issued then how to do it?

Regards
Aarya

baan1612 28th September 2015 19:21

Restricting completion of Operation
 
As per standard, this is the flexibility. If you want to restrict the operation not to complete without issuing the material, you need to build a small code in "tisfc010ue". you can build your own logic to check the material issue i.e. material should be issued completely or pro-rate etc...

let me know if you need any help on this. I did this for some customers.

Regards,
Gupta.

Aryaraj 29th September 2015 12:10

Dear Sir,

Do mean this can be done by user exit?

Regards
Aarya

baan1612 30th September 2015 03:00

Yes it can be done with user exit

Aryaraj 22nd February 2017 13:38

User exit defined but not working
 
Dear Sir as per your suggestion I have developed the user exit . It is working fine for complete material but not working for partial material. For example My production order is for 100 Nos which required 100 qty of BOM item. If 100 RM is not available then system gives error . But our requirement is system should allow to release order for 100 qty. But if I have RM for 10 qty then system should allow to confirm the operation for 10 qty but for next 90 qty system should give an error message. Can you please help me on this. Please refer my script. given below.
******************************************************************************
|* tisfc010ue 0 VRC B61C a cust
|*
|* baan
|* 17-12-15 [18:15]
|******************************************************************************
|* Script Type: Library
|******************************************************************************
#ident "@(#)tisfc010ue tiB61Cacust fp9 Rev.No. 2 17 Dec 15 baan"
table ttisfc010
table ttcibd001
table tbptmm120
table twhwmd215
table tticst001

string header(10000),line(10000),filename(200),filepath(200),path1(200),file.open.mess1(200)
string header1(10000),line1(10000),filename1(200),filepath1(200),path2(200),file.open.mess2(200),detail.var(10000)
long seq.id,ret
long seq.id1,ret1
extern domain tcbool issued.flag,hours.flag,hrs.req
extern domain tisfc.prtm max.hrs,min.hrs,short.hrs
extern domain tiqcp1 actqty

#include <bic_dal>
#pragma used dll ottdllbw
#include <bic_dal>


function extern long ue.before.before.save.object(long mode)
{
on case mode
case DAL_NEW:
break
case DAL_UPDATE:
create.file()

issued.flag = FALSE
select ticst001.*
from ticst001
where ticst001._index2 = {:tisfc010.pdno,:tisfc010.opno}
selectdo
| if ticst001.ques <> ticst001.qucs then
| issued.flag = TRUE
get.item.desc()
get.on.hand.qty()

|if ticst001.ques <> actqty then
|if ticst001.ques > whwmd215.qhnd and ticst001.qucs <=0 then |Meghna 18/12/2016
if ticst001.iswh <1 then
issued.flag = TRUE
|endif
endif
line = concat$("|",ticst001.pono,ticst001.sitm,tcibd001.dsca,abs(ticst001.ques-ticst001.qucs),whwmd215.qhnd,ticst001.cwar)
seq.puts(line,seq.id)
| endif
endselect

| hours.flag = FALSE
| select bptmm120.*
| from bptmm120
| where bptmm120._index5 = {:tisfc010.pdno,:tisfc010.opno}
| selectdo
| cal.short.hrs()
| if (bptmm120.hrea <> 0 or bptmm120.hrma <> 0) and bptmm120.proc = tcyesno.no then
| hours.flag = TRUE
| endif
| endselect
| if hours.flag or hrs.req then
| short.hrs = abs(tisfc010.maho - bptmm120.hrea)
| line1 = concat$("|",tisfc010.opno,bptmm120.tano,bptmm120.cwoc,bptmm120.mcno,short.hrs)
| seq.puts(line1,seq.id1)
| endif

if issued.flag then
dal.set.error.message("tigenstring", "Material Not Issued, Report Operations Cannot be Completed")
endif
| if hours.flag then
| dal.set.error.message("tigenstring", "Hours Not Processed, Report Operations Cannot be Completed")
| endif
| if hrs.req then
| dal.set.error.message("tigenstring", "Required Hours do not Match")
| endif
| if issued.flag or hours.flag or hrs.req then
| return(DALHOOKERROR)
| endif
if issued.flag then
return(DALHOOKERROR)
endif
close.file()
break
endcase
return(0)
}

function extern long ue.after.before.save.object(long mode)
{
on case mode
case DAL_NEW:
break
case DAL_UPDATE:
break
endcase
return(0)
}

function extern long ue.before.after.save.object(long mode)
{
on case mode
case DAL_NEW:
break
case DAL_UPDATE:
break
endcase
return(0)
}

function extern long ue.after.after.save.object(long mode)
{
on case mode
case DAL_NEW:
break
case DAL_UPDATE:
break
endcase
return(0)
}

function extern long ue.before.before.destroy.object()
{
return(0)
}

function extern long ue.after.before.destroy.object()
{
return(0)
}

function extern long ue.before.after.destroy.object()
{
return(0)
}

function extern long ue.after.after.destroy.object()
{
return(0)
}

function create.file()
{
filename = "Material_Not Issued_"&dte$()&".xls"
filename1 = "Hours_Not_Accounted_"&dte$()&".xls"
filepath = "E:\"&filename
filepath1 = "E:\"&filename1
seq.id = seq.open(filepath,"w")
seq.id1 = seq.open(filepath1,"w")

header = concat$("|","Position No","Item","Description","Shortage Qty","On Hand Qty","Warehouse")
seq.puts(header,seq.id)
header1 = concat$("|","Operation No","Task","Work Center","Machine","Short Hours")
seq.puts(header1,seq.id1)
}

function close.file()
{
seq.close(seq.id)
seq.close(seq.id1)

if issued.flag or hours.flag or hrs.req then
if issued.flag then

path1 = "C:\temp\"&filename
exec_dll_function( "ottdllbw" , "server2client" , ret, filepath, path1, 0 )
endif
if hours.flag or hrs.req then

path2 = "C:\temp\"&filename1
exec_dll_function( "ottdllbw" , "server2client" , ret1, filepath1, path2, 0 )
endif
endif
if issued.flag then
app_start(path1, "", "", "", "")
endif
if hours.flag or hrs.req then
app_start(path2, "", "","", "")
endif
}

function get.item.desc()
{
select tcibd001.*
from tcibd001
where tcibd001._index1 = {:ticst001.sitm}
selectdo
endselect
}


function get.on.hand.qty()
{
select whwmd215.*
from whwmd215
where whwmd215._index2 = {:ticst001.sitm,:ticst001.cwar}
selectdo
endselect
}

function cal.short.hrs()
{
max.hrs = 0
min.hrs = 0
short.hrs = 0
hrs.req = FALSE
max.hrs = tisfc010.prtm + (5*tisfc010.prtm/100)
min.hrs = tisfc010.prtm - (5*tisfc010.prtm/100)
if (bptmm120.hrea < min.hrs or bptmm120.hrea > max.hrs) then
hrs.req = TRUE
endif

}


All times are GMT +2. The time now is 02:24.


vB.Sponsors
©2001-2017 - Baanboard.com - Baanforums.com