f



Use ASP to read MS Access query that calls MS Access function

Hi:

I have an MS Access query for a table called MyTable.  One of my
fields in the query is a custom field that looks like "MyField: =
MyFunction(ID)" where ID is a field in MyTable.

I have ASP code and I can use it to read the query OK when "MyField"
is not part of the query.  If I add in MyField and then run my ASP
code to try to read all the query fields, I get an error message on my
web browser which says something to the effect of "cannot find
MyFunction."  On the Access side, I have MyFunction set up in a module
and use the keyword "Public" in front of the function name.  What else
do I need to do to get my ASP code to run this query.  I'm trying to
avoid reproducing MyFunction within the ASP code if possible.

Thanks.
Kevin

0
kmccrack (2)
6/14/2007 9:38:19 PM
comp.databases.ms-access 42670 articles. 0 followers. Post Follow

2 Replies
2050 Views

Similar Articles

[PageSpeed] 43

On Thu, 14 Jun 2007 21:38:19 -0000, k-man <kmccrack@gmail.com> wrote:

Sorry, no can do. From ASP you don't have access to the Access VBA
interpreter.

-Tom.



>Hi:
>
>I have an MS Access query for a table called MyTable.  One of my
>fields in the query is a custom field that looks like "MyField: =
>MyFunction(ID)" where ID is a field in MyTable.
>
>I have ASP code and I can use it to read the query OK when "MyField"
>is not part of the query.  If I add in MyField and then run my ASP
>code to try to read all the query fields, I get an error message on my
>web browser which says something to the effect of "cannot find
>MyFunction."  On the Access side, I have MyFunction set up in a module
>and use the keyword "Public" in front of the function name.  What else
>do I need to do to get my ASP code to run this query.  I'm trying to
>avoid reproducing MyFunction within the ASP code if possible.
>
>Thanks.
>Kevin

0
6/15/2007 1:52:32 AM
Yeah, I guess that's true.  I'm not really running MS Access itself am
I.  Guess I'll have to reproduce the code into ASP.

Thank you for the insight.

Kevin


On Jun 14, 9:52 pm, Tom van Stiphout <no.spam.tom7...@cox.net> wrote:
> On Thu, 14 Jun 2007 21:38:19 -0000, k-man <kmccr...@gmail.com> wrote:
>
> Sorry, no can do. From ASP you don't have access to the Access VBA
> interpreter.
>
> -Tom.
>
>
>
> >Hi:
>
> >I have an MS Access query for a table called MyTable.  One of my
> >fields in the query is a custom field that looks like "MyField: =
> >MyFunction(ID)" where ID is a field in MyTable.
>
> >I have ASP code and I can use it to read the query OK when "MyField"
> >is not part of the query.  If I add in MyField and then run my ASP
> >code to try to read all the query fields, I get an error message on my
> >web browser which says something to the effect of "cannot find
> >MyFunction."  On the Access side, I have MyFunction set up in a module
> >and use the keyword "Public" in front of the function name.  What else
> >do I need to do to get my ASP code to run this query.  I'm trying to
> >avoid reproducing MyFunction within the ASP code if possible.
>
> >Thanks.
> >Kevin- Hide quoted text -
>
> - Show quoted text -


0
kmccrack (2)
6/15/2007 5:20:48 AM
Reply:

Similar Artilces:

Create MS/ACCESS database app for non-ms/access users
Is it possible to create an MS/ACCESS database application and package it for users who do not have MS/ACCESS loaded in their PCs? I was told that this is possible, but I don't know what software is needed. Do you know? If so, please answer this post. Thanks. SueB *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! Per Sue Bricker: >Is it possible to create an MS/ACCESS database application and package >it for users who do not have MS/ACCESS loaded in their PCs? > >I was told that this is possible, but...

Possible to keep MS Access interface and migrate the MS Access to MS SQL Server?
Hello all Would it be possible to migrate the MS Access 2000 to MS SQL Server 2000? My application is using MS Access 2000 as database and as user interface such as forms. Now, I want to migrate the backend database from MS Access 2000 to MS SQL Server 2000. However, I want to keep the MS Access 2000 interface. Would it be possible? If I migrate the MS Access to SQL Server, would the queries, back-end VBA, macro, tables and forms be affected? Do I need to change the MS Access data type to SQL server supported data type? Which tool I can use to do the migration? Upsizing wizard or exporting...

Accessing MS ACCESS database using Data Environment
HI, I have developped a program in Visual Basic 6.0 using MS Access database. I have created all my reports through Data Environment where I have entered the location of my database file (for e.g c:\project\app\test.mdb) in the Connection properties. I have installed my application on another PC using Package & Deployment wizard. When viewing the reports on the other PC, I have to enter everytime the new location of the database. How can I solve this problem, please? nadia wrote: > HI, > I have developped a program in Visual Basic 6.0 using MS Access database. >...

Access MS-ACCESS database on server from client????
I m currently developing a java based application and want to know how can i make client access database located on the server? "HeMan_Speaks" <Lunar20092010@gmail.com> wrote in message news:d71ce567-0434-48b8-b1d2-bb191706ab45@w8g2000prd.googlegroups.com... >I m currently developing a java based application and want to know how > can i make client access database located on the server? I think you're going to have to expand a little bit more in your question here, as is not 100% quite clear what you're trying to do. You might want to make a little bit of a distinction between MS access, the development system that allows you to write code, build forms, and build reports, and that of the database engine that you choose to use with MS access. When you build an application MS access, you then choose your database engine, that might be oracle, SQL server, or perhaps more often leave the default jet database. So when you say make a client access application, are you talking about a piece of software that you plan to install and each computer? The fact that your introducing the issue of java further complicates your question. Perhaps your question is simply you have some java code running on a server, and with to open a mdb file (an access database file). In this situation you're not really using MS access at all here (you using what is called the jet database engine to read that mdb file). For all the trouble in this type of sce...

Read-Only ODBC Access to MS Access 2000
I have created an ODBC File DSN data source in Windows XP. I have successfully used this DSN to link tables from a Sybase SQL Anywhere database to Access 2000. How can you make this ODBC connection read-only? P.S. I would like to make the ODBC connection itself read-only (if possible) rather than adding security to the MS Access DB. ...

MATLAB command to access MS Access database
Hi! Is there a MATLAB command which gives access to a .mdb MS Access database or do I need a special driver? Thanks, Andree Hi Andree Ellert, you can use activeXcontrol to interact with MS-Access database. access = actxserver('Access.Application'); returns the handle for Access. set(access, 'Visible', 1); will show the opened Access window. use get(access) and set(access) commands to find the methods available to call. -Vadivelu M =========== http://www.mathworks.com/access/helpdesk/help/toolbox/database/datatool.shtml "Andree Ellert" <ellert@gmx.net/////\\\\\> wrote in message news:eed9874.-1@webx.raydaftYaTP... > Hi! > > Is there a MATLAB command which gives access to a .mdb MS Access > database or do I need a special driver? > > Thanks, > > Andree Andree Ellert wrote: > > > Hi! > > Is there a MATLAB command which gives access to a .mdb MS Access > database or do I need a special driver? > > Thanks, > > Andree <http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4045&objectType=file> -Hardik ...

request for explanation on access an database in ms access
This is the code that I found on the internet for accessing an ms access database: import java.sql.*; class Test { public static void main(String[] args) { try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); // set this to a MS Access DB you have on your machine String filename = "d:/java/mdbTEST.mdb"; String database = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ="; database+= filename.trim() + ";DriverID=22;READONLY=true}"; // add on to the end // now we can get the connection from the DriverManager Connection con = DriverManager.getConnection( database ,"",""); } catch (Exception e) { System.out.println("Error: " + e); } } } What I don't understand is the declaration of database. What I did was putting the database in the same dir as the sourcecode and use "jdbc:odbc:CafeJolt.mdb". But this doesn't work. And the above code does, why is that??? Actually it's not Java question. It's ODBC question. You have to have ODBC connection. Depending of Windows it's usually something like this (for my Windows 2000): Start->Sttings->Control Panel->Administartive Tools->Data Sources(ODBC)-> User DSN -> [Add]-> Driver to Microsoft Access(*.mdb) === And here, finally you can choose file name. ...

Access needs to be installed for me to use MS Access
Hi, Is it required for MS Access to be installed on machines on which I need to deploy windows app which uses MS Access as its backend. If no then how do I access and wrie to access database? Thanks, Vikas. <vikassah@gmail.com> wrote in message news:1166161668.556801.183030@n67g2000cwd.googlegroups.com... > Hi, > > Is it required for MS Access to be installed on machines on which I > need to deploy windows app which uses MS Access as its backend. If no > then how do I access and wrie to access database? If Access, or the Access runtime (from the developer extensio...

Accessing MS-Access from OpenRoad using ActiveX
Hi I'm wanting to conect to an MS-Access MDB file from an OpenRoad program using ActiveX. Can someone tell me the files I need to use/register for Windows XP? Any other help or suggestions would be most appreciated. Darren dharvey911@hotmail.com ...

accessing ms access via ODBC without Microsoft Access
Hi, If I have a computer without Microsoft Access installed but with an ODBC connection to a .mdb file - can I still access the 'database' via ODBC? thanks Tim <timasmith@hotmail.com> wrote in message news:1145206985.433826.106120@i40g2000cwc.googlegroups.com... > Hi, > > If I have a computer without Microsoft Access installed but with an > ODBC connection to a .mdb file - can I still access the 'database' via > ODBC? Yes, provided you are running a program prepared in a language that supports ODBC and have installed an ODBC driver on that user'...

How to access MS Access from Perl?
Hi, Good day! I am writing some Perl script on the server side for HTML forms that can create/update an MS Access database. Does anyone know of examples how this can be done? Your help is greatly appreciated. -lc Email to luican@yahoo.com bounces. Anyway, try DBI and DBD::ODBC. Or maybe DBD::ADO, but I've never tried it. ---------------------------------------- http://cpan.org http://search.cpan.org/~jurl/DBD-ODBC-1.09/ODBC.pm ... Connect without DSN The ability to connect without a full DSN is introduced in version 0.21. Example (using MS Access): my $DSN = 'driver=Mi...

How to get Graphs from MS Access and use them in MS Powerpoint
Is there any easy way how to use graphs created in MS Access 2000 in Powerpoint?Especially when I need to use about 20 of them. Is there any development in Office 2003? Oskar *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! Instead of creating the graphs in Access, perhaps you should use vba either (a) to open Powerpoint from within Access and create the graph by pushing data into a Powerpoint template of your own design or (b) start Powerpoint and open the Access database in code and pull the data into a graph. Eith...

Running a ms access database with access 2003 in Vista
I have a Database that I am trying to run on a new vista computer. Up to now I was running it on a win 98 computer and using access 2003! I installed access 2003 and I can make it run and view the data but I can not save any new records. Has any one seen this problem yet? Thanks Clarence Wollman On Wed, 22 Aug 2007 13:17:13 -0700, cwoll <clarencewollman@gmail.com> wrote: Do you have the same problem with the Northwind sample application? (search your computer for northwind.mdb) -Tom. >I have a Database that I am trying to run on a new vista computer. Up >to now I was running it on a win 98 computer and using access 2003! I >installed access 2003 and I can make it run and view the data but I >can not save any new records. >Has any one seen this problem yet? > >Thanks Clarence Wollman On Aug 22, 7:29 pm, Tom van Stiphout <no.spam.tom7...@cox.net> wrote: > On Wed, 22 Aug 2007 13:17:13 -0700, cwoll <clarencewoll...@gmail.com> > wrote: > > Do you have the same problem with the Northwind sample application? > (search your computer for northwind.mdb) I don't have a problem opening and editing the northwind.mdb. Thanks Hi I found a workaround. This database has a fronted and a backed. When I link them in the linked table manager, I was going threw the network to my computer. The reason I am doing this is when any networked computer opens the shortcut to the front end of this computer the linked table manger knows...

Best way to access a remote MS ACCESS database
What is the best way, via the internet, to access a remote Microsoft Access database? I was thinking of using VPN, but I thought that I would check here to see if there is a better way. Any suggestions? Thanks Do you mean remotely controlling an Access database, or linking tables over the internet? The first is doable, the second is a recipe for disaster. Remote Control: If your remote OS is Windows XP, you can use Remote Desktop (although only 1 person can access the PC at a time; this will change in the upcoming Service Pack for XP, but that may not help you now). Otherwise, GoToMyPC offers similar services, as does Terminal Server (a component of a Windows Server machine), PCAnywhere, et al. Linking to remote tables: You will almost certainly encounter severe problems with corruption, and your performance will almost certainly be so poor as to be unworkable. I attempted this once, with a web server in Canada and my machine in Augusta, GA. Even tiny data requests on a very well optimized data structure took waaaay too long to process ... it's simply not workable, IMO. Other alternatives would be covert the app to a web-based and place your data on a web server. Access/Jet isn't really designed for those workloads, but running a small site with minimal transactions and users can be done. Otherwsie, consider switching to a more robust data platform like MySQL, SQL Server, etc. -- Scott McDaniel CS Computer Software Visual Bas...

Using VBA to toggle from MS Word to MS Access?
Access 2003, Windows XP SP2 I have an application that generates a word document populated with a variety of fields from Access tables. The word document is generated when the user presses a button (cmdGenerateAgreement) on a form (frmTransaction). I want the process to work as follows: 1. User presses button 2. Word document is opened and populated 3. Access screen becomes visible with a message box 4. User presses Ok 5. Word screen becomes visible for finalization My question is how do I achieve steps 3 and 5? I've tried SetFocus, Access Web's API: Manipulate Window (fSetAccessWindow), and a lot of browsing in the newsgroups. Nothing seems to work. My guess is that this functionality will require a call to the Windows API. I've read all the relevant sections in my Access books, and nothing specific to this situation is mentioned. Can this functionality be accessed using VBA? If so, any help or direction would be appreciated. If not, can anyone think of a work around? Thank you, Kelii My super easy merge does all 5 steps...and you can "enable" ANY screen for merge with ONE line of code.... The sample I have can be found here: http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html What is nice/interesting about my sample is that is specially designed to enable ANY form with ONE LINE of code.... Thus, each time you build a new form, you can word merge enable it with great ease. Make sure you read the instructions from above, and y...

Accessing a MS Access database across two servers
Hi The technical support guys at my company have set up my system so that the server containing the MS Access database is on one server, while the pages that should access the database are on another server. When the pages and database are on the same server, I usually just connect through ODBC. The problem is that I don't know how to set up an ODBC connection to link from one server to a database in another. Anyone know what I am getting at and know of a possible solution, or a link to a site which may help. thanks in advance Brendan "Singularity" <Brendan.Collins@Sin...

accessing MS Access database fila via ODBC problem
Hi! I'm trying to connect to a MDB file via ODBC like this: char *DSN = "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=c:\\dev-cpp\\test\\1.mdb"; SQLAllocEnv(&env); SQLAllocConnect(env, &hdbc); SQLBrowseConnect(hdbc, (UCHAR*)DSN, strlen(DSN), (UCHAR*)buf, BUF_SIZE, (SQLSMALLINT*)&rcvlen); The function SQLBrowseConnect fails and SQLGetDiagRec returns "IM001 Driver does not support this function" Can anyone help me? Thanks! David On S...

Use of Access 2002-2003 structure in MS Access 2007
Dear reader, Is it possible to run in Access 2007 an application designed in Access 2002-2003 format? Tanks for any assistance. Kind regards and all the best for 2009 Simon ...

Using Iseries Access ODBC Driver with MS ACCESS 2003
When Trying attaching databases into MsAccess2003 using Iseries Access ODBC Driver (I'm in OS400 v5r2) I get an error message according to which the duration of connection is too long and so I can't attach the database although I got the list of the tables in the library I specified. Can anyone help me ? Thanks in advance. The timeout to dispay de data is small. You need to increase this timeout. The problem can occur when the tables are very very very (but very) big. "Bertrand Bard" <bbard@dehon.com> escribi� en el mensaje news:d01a5cc.0404280030.58f11d3e@posting.go...

Accessing 2 tables having same name but different databases ms-access
Hi, I have an application with MS-Access as backend and JSP/ tomcat as frontend/webserver. For getting better response time(as access is very slow compared to other RDBMS's), I have split the main DB into two DB's on different disks on my server for better performance.I have kept the table names same but changed the DB names. How do I access tables from both the DB's? This is what I have done; I made different connection to the respective DB's i.e. con and con2. When I want to access data, I am using 2 result sets for retriving data from the tables, but getting no result. Here is my code: rs2_1=stmt2_1.executeQuery("select * from Requests where Status='Released' AND LoginName='"+login+"' order by Req_No"); rs=stmt.executeQuery("select * from Requests where Status='Released' AND LoginName='"+login+"' AND Req_No> 5500 order by Req_No"); So, rs & stmt are for latest records and rs2_1 & stmt2_1 correspond the records from older DB. I think, I'm forgetting some small thing but cant get it. Please advice. What do you mean "no result"? Does "next()" return false for both rs2_1 an= d rs? If you're really trying to improve response time, you should probably be ru= nning the two queries in separate threads ... but as you acknowledge, Acces= s may not have as high performance as other RDBMSs. You would also see rel= iability adv...

left() and right() function in MS SQL vs MS ACCESS
I normally use MS ACCESS vs MS SQL,, which has a left() and right() function. I need to use MS SQL for this project but I am not familiar with it. I have read a few books, but can not figure out how to do this. Please help. If I need to compare the first 4 letters of a field, with the first four letters of another field, how can I do this? Select field1, field2 FROM table1 Where left(field1,4)=left(field2,4) (MS SQL does not have left() and right() functions) Please help. In addition, I have a CSV file with data like 10.20, which I import inrto a numberic field. Unforunately the value...

MS Access Database Query
Hi, first of all I have to say I'am new to MS Access, I'm used to database systems like Oracle or MySQL. I created a simple database consisting of a single table and a form to fill in new entrys and search for existing entrys. But the search function that Access generates as I created the proper button is way to simple, I need a function that enables to search in several columns. I saw a few quite simple examples where this was done by DAO, but this doesn't work with a .mdb database, does it? (Access allways replies 'Unknown user datatype' once it gets to the line: 'Dim...

Reading an MS Access Database file on *NIX platform using PHP
I'm building a small web application for a friend using PHP. He'd like to use MS Access to keep the data in, and update the data on the site by FTP'ing Access files he edits on his machine up to the web host. The web host is unix-based (FreeBSD, slightly hacked by Verio, I believe), so this means COM functions aren't available. ODBC was my next thought, but I've never used it, and there are a few things I don't understand. Setting up a DSN is one of them -- apparently this isn't as simple as constructing a string, and all the tutorials I can find seem to involve ...

Use of Access 2002-2003 structure in MS Access 2007 #2
Dear reader, Is it possible to run in Access 2007 an application designed in Access 2002-2003 format? Tanks for any assistance. Kind regards and all the best for 2009 Simon Simon van Beek wrote: > Dear reader, > > > > Is it possible to run in Access 2007 an application designed in > Access 2002-2003 format? > > > > Tanks for any assistance. > > > > Kind regards and all the best for 2009 > > Simon Yes. There might be some issues, though, depending on how you've programmed the db. Best suggestion, in my eyes, would be testing and playing around a little with *a* *copy* of the database and see what turns up. Most likely, you'd need to set the directory in which the database resides, as a trusted location. A very good sumup of "the good, bad and ugly" ;-) of Access 2007 is this list by Allen Browne http://allenbrowne.com/Access2007.html -- Roy-Vidar Simon, Best wishes to you too. One question: why do you use so many carriage returns in your messages? They cause readers having to unnecessary scroll. Thanks, John "Simon van Beek" <SvanBeekNL@Versatel.nl> schreef in bericht news:495f3ebf$0$28733$bf4948fe@news.tele2.nl... > Dear reader, > > > > Is it possible to run in Access 2007 an application designed in Access > 2002-2003 format? > > > > Tanks for any assistance. > > > > Kind regards and all the best for 2009 > > Simon >...

Web resources about - Use ASP to read MS Access query that calls MS Access function - comp.databases.ms-access

Wave function - Wikipedia, the free encyclopedia
... (a ball attached to a spring ) in classical mechanics (A-B) and quantum mechanics (C-H). In quantum mechanics (C-H), the ball has a wave function ...

Eating chocolate 'improves brain function' - study
... news for those with a sweet tooth - a recent study has found that regular chocolate consumption is associated with better cognitive function. ...

Using Functions to Make Better Abstractions
... (code that is tightly coupled to its own implementation details). I was wrong. I was wrong because I had an incomplete understanding of functions. ...

Cisco launches new network functions virtualization infrastructure solution to help service providers ...
Al-Bawaba Cisco launches new network functions virtualization infrastructure solution to help service providers run network ... Al-Bawaba ...

Google Maps for iOS adds detour function, 3D touch support
Google has extended its pit-stop feature the ability to find places to stop off on journeys to iPhone and iPad users with the release of Google ...

LVMH's Hublot May Be Next Brand for Smart Functions, Biver Says
Hublot will probably be the next LVMH watch brand to add smart functions, following TAG Heuer’s footsteps in combining Swiss craftsmanship and ...

Yahoo Begins Grim Job of Closing Functions, Laying Off Staff
Yahoo Food is closing, and other digital magazines on tech, travel and beauty are also scheduled for closing or major cutbacks.

Engineers 3D Print Tissue That Mimics How The Human Liver Functions
Engineers say they have 3D printed life-like liver tissue that could be a new platform in the lab to test the efficacy of drugs saving pharmaceutical ...

A 3D Printed Jet Engine Appears to Function
... jet engine . You may remember seeing a 3D printed jet engine grace our front page back in October. That one was beautiful didn’t function . ...

Supreme Court Justices Can Still Function With Eight
... Domain, https://commons.wikimedia.org/w/index.php?curid=7990759] But as to whether the remaining Supreme Court justices will be able to function ...

Resources last updated: 3/20/2016 10:56:11 PM