I am try to get all the partbin row for a part to indicate to the user if this part have multiple bin in the select warehouse.
bool recSelected = false;
bool multipleselect = true;
string strPartNum = txtPart_custom.Text.ToString();
// Define the whare clause for the lookup. Whatever would work in a standard
// SQL where clause will work here.
string whereClause = "PartNum = '" + strPartNum + "'" ;//+ " and WarehouseCode = '" + strWarehouseCode+ "'" ;
// Here is where we actually call listLookup. The only thing you need to
// ever change here is where we have "JobMtlSearchAdapter".
DataSet dsPartBin = SearchFunctions.listLookup(
oTrans
,"PartBinSearchAdapter"
,out recSelected
,false
,whereClause
,multipleselect
);
if(recSelected)
What i am doing wrong? the “recSelected” is false every time and the dataset is null…
@Alaric_Planes I would start by debugging in VS and making sure that strPartNum actually held a value. Then copy out the whereClause after it is assigned to test in SSMS. It might be as simple as needing a Trim on txtPart_custom.
@gpayne i don’t have acces to VS Debugging, i tried with hardcore code value selected from database and i got same result.
I use several listlookup before and is the only that don’t want to work …
@markdamen BL tester nice tool, @Chris_Conn yes you’re rigth i can’t see this method in bl tester.
I’ll check boreaders instead or use use an other tool.