Hi everyone

This is my first post so please help me out !! ;)

I am writting an application in VB.NET to print orders. The orders are shown on screen in a listview and the user can select individual orders/range of orders to print.

This Access query looks like:

PARAMETERS OrderIds Text ( 255 );
SELECT orders.*, orderdetails.*
FROM orders, orderdetails
WHERE orders.orderid=orderdetails.orderid And orders.orderid IN (OrderIds);

How do I from vb.net pass the OrderIds parameter into this query with mulitple orderids?

e.g. passing "123-456" works
passing " '123-456', '123-789' " doesn't.

Thanks

Darren

Hi everyone

This is my first post so please help me out !! ;)

I am writting an application in VB.NET to print orders. The orders are shown on screen in a listview and the user can select individual orders/range of orders to print.

This Access query looks like:

PARAMETERS OrderIds Text ( 255 );
SELECT orders.*, orderdetails.*
FROM orders, orderdetails
WHERE orders.orderid=orderdetails.orderid And orders.orderid IN (OrderIds);

How do I from vb.net pass the OrderIds parameter into this query with mulitple orderids?

e.g. passing "123-456" works
passing " '123-456', '123-789' " doesn't.

Thanks

Darren

Hi Darren
I'm not sure I can answer your question but I wrote an application for
Coumadin Dosing / Database where I use Crystal Reports to print out
my records. Take a look at my web site http://www.pace-med-apps.com/Warfarin2.aspx
near the middle of the page. If this looks like some thing that may be helpful
then email me drp@spmd.us

Take Care
Scott

Hi Scott

Thanks for your reply.

That app looks good although I have no ides what its doing !!

Im not sure if that is right for my app. I need to pass in a list of orderids and return all the details for them. You seem to be passing in one and potentailly returning many (if you use wildcards).

Ive had an answer on another forum but i havent worked out how to use it yet.

Thanks

Darren

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.