QuoteAsmSearchAdapter "GetList is not supported"

I created a button on a dashboard “btnQuoteSeach” that when you click should allow you to search for a quote/asm (similar to the one used by engineering workbench → get details → Quote). Problem is when I click the “Seach” I get the error: “GetList is not supported”

This is the code I am using. I cannot figure out why the GetList isn’t working. I see Erp.Adapters.QuoteAsmSearch does have a “GetList” method. Why would I be getting a “GetList” error.

private void btnQuoteSearch_Click(object sender, System.EventArgs args)
	{
		
        bool recSelected;
        string whereClause = "(AssemblySeq = 0 AND Template = 1 BY PartNum) AND PartNum >= 'TEST'";
        System.Data.DataSet dsQuoteAsmAdapter = Ice.UI.FormFunctions.SearchFunctions.listLookup(this.oTrans, "QuoteAsmSearchAdapter", out recSelected, true, whereClause);
        if (recSelected)
        {
          System.Data.DataRow adapterRow = dsQuoteAsmAdapter.Tables[0].Rows[0];

          //map search fields to application fields
          EpiDataView edvQuoteAsm = ((EpiDataView)(this.oTrans.EpiDataViews["V__ENG_GETDTL_1View"]));
          System.Data.DataRow edvQuoteAsmRow = edvQuoteAsm.CurrentDataRow;
          if((edvQuoteAsmRow != null))
          {
            edvQuoteAsmRow.BeginEdit();
            edvQuoteAsmRow["numCalculated_cFromQuoteNum"] = adapterRow["QuoteNum"];
            edvQuoteAsmRow["numCalculated_cFromQuoteLine"] = adapterRow["QuoteLine"];
            edvQuoteAsmRow.EndEdit();
          }
       }
	}

QuoteAsmSearchAdapter has a GetRows, not a GetList

public QuoteAsmSearchDataSet GetRows(string whereClauseQuoteAsmSearch, int pageSize, int absolutePage, out bool morePages)

No GetList in the dll

This thread may be of interest to you.

I added:

using Ice.Proxy.Lib; //BO Reader
using Ice.Core;
using Erp.BO;
using Ice.BO;


public class Script
{

    BOReaderImpl _bor;

	public void InitializeCustomCode()
	{

        _bor = WCFServiceSupport.CreateImpl<Ice.Proxy.Lib.BOReaderImpl>((Ice.Core.Session)oTrans.Session, Ice.Contracts.BOReaderSvcContract.UriPath);

	}

But I am getting the error now:
‘Ice.Contracts.BOReaderSvcContract’ does not contain a definition for ‘UriPath’

I still want the QuoteAsmSearchAdapter to open up and allow me to select the quotenum/line and return back to the dashboard.

I just changed my code to use the QuoteDtlSearchAdapter - and that one will work. The QuoteAsmSearchAdapter is being used from Engineering Workbench → Get Details … so not sure why it works from there, but I can’t see the code Epicor is using to call the QuoteAsmSearchAdapter.

Thank you klincecum for your thoughts and help.

Here is how Epicor does your first question on the engineering workbench.

//references

//Erp.Adapters.QuoteAsm.dll
//Erp.Adapters.QuoteAsmSearch.dll
//Erp.Contracts.BO.QuoteAsm.dll
//Erp.Contracts.BO.QuoteAsmSearch.dll

using Erp.UI.Searches;
using Erp.Adapters;

	private void epiButtonC1_Click(object sender, System.EventArgs args)
	{
		QuoteAsmSearchAdapter quoteAsmAdapter = new QuoteAsmSearchAdapter(this.oTrans);

		string text = "AssemblySeq = 0";
		text += " AND Template = 1 BY PartNum";
		
		SearchOptions searchOptions = new SearchOptions(SearchMode.ShowDialog);
		searchOptions.PrimaryTableName = "QuoteAsmSearch";
		searchOptions.PreLoadSearchFilter = text;
		searchOptions.DataSetMode = DataSetMode.RowsDataSet;
		searchOptions.SelectMode = SelectMode.SingleSelect;
		
		QuoteAsmSearchForm quoteAsmSearchForm = new QuoteAsmSearchForm();
		quoteAsmSearchForm.BasicPanelWhoCalled = "Erp.UI.GetDetailsEntry";
		quoteAsmAdapter.SearchForm = quoteAsmSearchForm;
		
		//quoteAsmSearchForm.StartWithText = "";
		
		quoteAsmAdapter.InvokeSearch(searchOptions);
		
		if (quoteAsmAdapter.QuoteAsmSearchData.QuoteAsmSearch.Rows.Count > 0)
		{
		    string quoteLine = quoteAsmAdapter.QuoteAsmSearchData.QuoteAsmSearch.Rows[0]["QuoteLine"].ToString();
		    string quoteAssemblySeq = quoteAsmAdapter.QuoteAsmSearchData.QuoteAsmSearch.Rows[0]["AssemblySeq"].ToString();
		    string quoteNum = quoteAsmAdapter.QuoteAsmSearchData.QuoteAsmSearch.Rows[0]["QuoteNum"].ToString();
		}
	}

Thanks, going to try it tomorrow.
Is there a decompiler/tool that you use to see the Epicor logic behind the Eng WrkBench → Get Details → Quote button?

I turned on customization mode so I could see what form it was calling, and traced from there.

I used DNSpy, but I don’t recommend it as it’s no longer in development, and there were
some hacks not long ago that put out bad downloads of it.

I don’t know what the best is now. @josecgomez ?

RedGate Reflector is “legit” and Professionally Maintained
Dot Peak is “free” (as in beer) and pretty good dotPeek: Free .NET Decompiler & Assembly Browser by JetBrains

I still like DNSpy (the revival) I even contributed to it a few months back to fix a Bug that prevented Debugging in IIS :slight_smile:

1 Like

yep, I see you…

Introduce a workaround for a .NET 6.0 bug that occurred when a debugger was attached to a process that utilized dynamic modules. (by @josegomez)

LMAO how’d you find that so fast I couldn’t even find it haha

1, I have extremely good pattern matching skills.
I look at a page, and I see patterns, kind of like those freaks with photographic
memories, except I don’t retain it, nor read it that fast.

2, I went to the download page, and I’m on here so much, when I scrolled down
an immediate pattern stood out … @josegomez :rofl:

Thank you - I found what you were referring to with DNSpy