Pur-UKN BPM to Assing Warehouse

Hello Devin, you could intermingle C# wih VB via customization.

 

For example, the receipt entry form customization was written in VB.net by some contractor.

 

On the mass receipt, I was able to add my C# code to it.

 

That works and sure you could do it with a BPM as well.

 

 

 

 

Does any one have a BPM that assings a warehouse for anything that = pur-ukn?  Any help would be appreciated I am on Version 9.05.702 Progress x64


Thanks

I wrote a customization in C# for Mass Receipt Entry. One of my collegues said I could have done it with a bpm but I choose C#. Anyways via code, on blank warehouses, I eithier looked up the warehosue using adapters or I assigned a NONSTOCK and set the default bin.  I will be happy to show you my code if you need something like that.

that could work as we already have some customization on that screen. 

What screen are you looking at?

Mass receipts

Ok is it okay if I pasted code here? I mean would anyone object?

private void updateMassReceiptAdapter(int vendorNum, string purPoint, string packSlip)
      {
         ReceiptAdapter ra = new ReceiptAdapter(this.oTrans);
        
         ra.BOConnect();

         bool result = ra.GetByID(vendorNum,purPoint,packSlip);
        
         if((result))
            {


              for(int i = 0; i < edvRcvDtl.dataView.Count; i++)        
              {
                     //string testWhc = edvRcvDtl.dataView[i]["WareHouseCode"].ToString();

               if(edvRcvDtl.dataView[i]["WareHouseCode"] == string.Empty )    
               {
                    
                   if(string.IsNullOrEmpty( getWareHouseFromPO(int.Parse(edvRcvDtl.dataView[i]["PONum"].ToString() ))))
                    {
                          edvRcvDtl.dataView[i].BeginEdit();
                       edvRcvDtl.dataView[i]["WareHouseCode"] = "NS";
                       edvRcvDtl.dataView[i]["WareHouseCodeDescription"] = "NONSTOCK";
                       edvRcvDtl.dataView[i]["BinNum"] = "1";
                          edvRcvDtl.dataView[i].EndEdit();
                    }
                       else
                        {
                          edvRcvDtl.dataView[i].BeginEdit();
                       edvRcvDtl.dataView[i]["WareHouseCode"] =
                                         getWareHouseFromPO(int.Parse(edvRcvDtl.dataView[i]["PONum"].ToString()));

                       //edvRcvDtl.dataView[i]["WareHouseCodeDescription"] = 
                                     //getWareHouseDescFromPO(int.Parse(edvRcvDtl.dataView[i]["PONum"].ToString()));

                          edvRcvDtl.dataView[i]["BinNum"] = 
        getBinNum(edvRcvDtl.dataView[i]["PartNum"].ToString(),getWareHouseFromPO(int.Parse(edvRcvDtl.dataView[i]["PONum"].ToString())));

                          edvRcvDtl.dataView[i].EndEdit();
                        }
 
               }
                   
                
              }


               ra.Update();
            }
          ra.Dispose();
      }

Hello Devin, did the code I sent help?

I  haven't had a chance to test yet looking at the code right now to see if it will work.  thanks for the the quick reply and everything.

Looks like I have some work to do as our code is in VB not C#  but I think a BPM would be the better answer any one else have some ideas on what the BPM would look like.


Im thinking In the BO.MassReciept.update


Have a condition on for purchase type = ukn

Set warehouse.code to SE1 which is our warehouse

and bin to RECV which is our default receving bin.