Click here to Skip to main content
15,900,906 members

Comments by J Melkerson (Top 1 by date)

J Melkerson 13-Sep-13 7:08am View    
After I posted the question, I realized I didn't ask it very well. I want to refactor (or apply a pattern or something) the two try blocks such that I can pass "SalesOrderMasterTable" (or something that resolves to it) into the first block and then pass "InvoiceHistoryTable" into the second block thereby eliminating the duplicate code.

I want to eliminate the duplicate code but the names of the tables being queried are in the linq query statements and I don't know how to pass table names as variables to linq queries.

Hope that helps clear things up.