|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
linking MS-Acess query to a public function in a moduleI want to use VB.net2005 environmment with access database I loaded the tabels and queries only to VB2005 The code and parameters' queries did not load I have no problem to rewrite code in VB.net syntax BUT the problem is that VB.net is unable to link its code to the database for example it loaded a table, say emploee table, a query should be built to geather those having 3 years or more and to raise there salary according to specific function NewSalary(DateOfStart, BasicSalary, PositionID) This was done in Access by simply definig Public function in a module and every thing ok When I defined a public function in VB.net, the query can not identify that function and returns an error. In SQL server the stored procedures fixed the problem but in access database no stored procedures. What Can I Do to make the access engine read VB.net public functions? Thanks in advance Dr. M. B. N. Novice programmer,
Why do you think that there are no stored procedures in access. There defintly are, however probably can you better use the dataview with its rowfilter, which is probably easier for you to use. http://msdn2.microsoft.com/en-us/library/system.data.dataview.aspx Links showed in past to this newsgrouip by Paul about Access sQL http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnacc2k/html/acfundsql.asp http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnacc2k/html/acintsql.asp http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnacc2k/html/acadvsql.asp I hope this helps a little bit? Cor Show quote "NoviceProgramer" <hgnov3***@gmail.com> schreef in bericht news:1171702395.562904.39130@l53g2000cwa.googlegroups.com... > Hi Every body > > I want to use VB.net2005 environmment with access database > > I loaded the tabels and queries only to VB2005 > The code and parameters' queries did not load > > I have no problem to rewrite code in VB.net syntax > > BUT the problem is that VB.net is unable to link its code to the > database > > for example it loaded a table, say emploee table, a query should be > built to geather those having 3 years or more and to raise there > salary according to specific function NewSalary(DateOfStart, > BasicSalary, PositionID) > This was done in Access by simply definig Public function in a module > and every thing ok > When I defined a public function in VB.net, the query can not identify > that function and returns an error. > In SQL server the stored procedures fixed the problem but in access > database no stored procedures. > > What Can I Do to make the access engine read VB.net public functions? > Thanks in advance > > Dr. M. B. N. > On 17 Feb 2007 00:53:15 -0800, "NoviceProgramer" <hgnov3***@gmail.com> wrote: ¤ Hi Every body¤ ¤ I want to use VB.net2005 environmment with access database ¤ ¤ I loaded the tabels and queries only to VB2005 ¤ The code and parameters' queries did not load ¤ ¤ I have no problem to rewrite code in VB.net syntax ¤ ¤ BUT the problem is that VB.net is unable to link its code to the ¤ database ¤ ¤ for example it loaded a table, say emploee table, a query should be ¤ built to geather those having 3 years or more and to raise there ¤ salary according to specific function NewSalary(DateOfStart, ¤ BasicSalary, PositionID) ¤ This was done in Access by simply definig Public function in a module ¤ and every thing ok ¤ When I defined a public function in VB.net, the query can not identify ¤ that function and returns an error. ¤ In SQL server the stored procedures fixed the problem but in access ¤ database no stored procedures. ¤ ¤ What Can I Do to make the access engine read VB.net public functions? ¤ Thanks in advance There is no support for custom user functions when running Jet SQL through DAO, ADO or ADO.NET. Paul ~~~~ Microsoft MVP (Visual Basic) |
|||||||||||||||||||||||