Shoutbox

Some help with VB 6 - Printable Version

-Shoutbox (https://shoutbox.menthix.net)
+-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58)
+--- Forum: Skype & Technology (/forumdisplay.php?fid=9)
+---- Forum: Tech Talk (/forumdisplay.php?fid=17)
+----- Thread: Some help with VB 6 (/showthread.php?tid=31565)

Some help with VB 6 by Salem on 09-15-2004 at 05:25 PM

Hi

Please can sone one help me with the following

1) I wrote a program in Visual Basic 6 for a database i created in Microsoft Access 2003. I also included a search feature to search for a entry. I would like to know what SQL code to use to search for a word in a field of my database. currently if you are looking for "Hello To You" in the database you must type the full phrase "Hello To You". I want it to be able to find that entry even if you type "Hello", "To" or even "You". I hope you understand what i mean. Please can someone give me an example of the SQL code to use?

2)I have integrated Windows Media Player 9/10 into a VB program wrote. Does anyone know if i can get the VB program to bring up the Statistics screen of WMP when i click on a button. I have looked at both the WMP 9 and WMP 10 SDK help stuff, but cant find anything.

Thanx in advance

RileyM


RE: Some help with VB 6 by CookieRevised on 09-15-2004 at 09:14 PM

1) A nice trick to do if you don't know enough about SQL is to do this with a query inside Access itself: Build up the query (using the wizards, help function, etc..) and after you have the correct query of your likings, view the "SQL-code" of that query (top-left button in the buttonbar where you can select "query-view", "result-view", "SQL-view")

2) Dunno... maybe the method "SendKeys" will do it for you (although very crappy thing to use in almost all cases)... or maybe there is an API for it... just guessing here...


RE: RE: Some help with VB 6 by Salem on 09-16-2004 at 07:41 PM

quote:
Originally posted by CookieRevised
1) A nice trick to do if you don't know enough about SQL is to do this with a query inside Access itself: Build up the query (using the wizards, help function, etc..) and after you have the correct query of your likings, view the "SQL-code" of that query (top-left button in the buttonbar where you can select "query-view", "result-view", "SQL-view")

2) Dunno... maybe the method "SendKeys" will do it for you (although very crappy thing to use in almost all cases)... or maybe there is an API for it... just guessing here...


I do know how to write SQL code myself, i'm just not sure how to get it to search for something that is similar rather than identical to an entry in my database. Is this possible?

RileyM
RE: Some help with VB 6 by CookieRevised on 09-16-2004 at 10:05 PM

Well, do as I suggested in that first point. Use Access itself to build up the query. When you're finished and you have the output that you want, press on the "SQL"-button and it will present you with the proper SQL-query... To work in Access you don't need to know SQL at all (it helps though)


RE: Some help with VB 6 by RaceProUK on 09-20-2004 at 08:55 AM

quote:
Originally posted by CookieRevised
To work in Access you don't need to know SQL at all (it helps though)
There are a few types of query you have to know SQL for, but they are quite rare tbh.