How To Use Application.run
strCode = Me.CodeToRun
I select what action type I want to perform (3 is to run code) and it works as long as I don't have to pass along a variable such as if I wanted to call this function:
Function closeMe(Optional pF As Form) As Byte
I am not sure how I can alter this to allow me to call functions/subs that have more than just a "name" that can be a string.
Hope I explained this good enough to get some assistance to point me in the right dirrection.
Thank you for taking the time to report an issue.
What's wrong... Please write below.
I have created a toolbar control, which allows the user to close the application, and have the procedure tied up to this. This works fine.
But I have been unable to make it run if the user chooses to close the application by clicking the 'Close' button in the upper right corner.
My question is if there is an 'application_close' event (or similar) which I can use to run my clean up code, or if I (as an alternatively solution) can disable the 'Close' button
The issue I have is that there are some VBA codes in my application which refer to paths and paths vary from PC to PC.
For instance, a VBA code for my application could be Application.followhyperlink "C:/Users/Jack/Desktop/trial.xls" while the same line of code could be
Application.followhyperlink "C:/Users/Sam/Desktop/trial.xls" on another PC
Is there a way I can create a general path for this line of code that will run on any PC?
Is there a trick to this? How do I get the macro to run even if the MDB is open by another application?
Run time error "404" Methog "run" of object _Application failed.
I have put "Excel.application.quit" at the end of the Marco.
Code I'm using:
Dim xlsApp As Excel.Application
Dim xlswkb As Excel.Workbook
' Set xlsApp = CreateObject("Excel.application")
Set xlsApp = New Excel.Application
Set xlswkb = GetObject("M:\Terry\201005_LIM MISO Data\Get LIM MISO Data_052810_tab.xls")
Excel.Application.Visible = True
xlswkb.Application.Run ("ReadMIM") (get error this stmt)
Set xlsApp = Nothing
Set xlswkb = Nothing
So, I have APplication 1, 1234,1235,1236
Application 1, 1234
Application 1, 1235
Application 1, 1236
and so on.
Is this possible, just in SQL?
I have tried using (Select A_Number from tbl_A_Numbers where A_Number.Application_ID=tbl_A_Numbers.Application_ ID) and it doesnt work
Dim appAccess As Access.Application
' Create instance of Access Application object. Set appAccess = CreateObject("Access.Application")
' Open WizCode database in Microsoft Access window.
appAccess.OpenCurrentDatabase "B:\Documents and Settings\bconner\Desktop\Template Month End Reports v1.2.mdb", False
' Run Sub procedure.
appAccess.Run "MonthEndReports" Set appAccess = Nothing
Assuming connection to the Internet for the client pc, I thought of having the application communicate stealthily with a Web site and depending on some value on the Web site to take appropriate action such as prevent user from running the software.
The application can sense whether or not it is connected to the Internet and can even send text messages.
On the specific Web site, I may have a table (hidden) with two columns, the user license id and a boolean indicating whether the user is allowed to run the application or not