Modules & VBA :: How To Turn Off Bluetooth And WiFi
Feb 22, 2015How can I turn off wifi and bluetooth using vba
View RepliesHow can I turn off wifi and bluetooth using vba
View RepliesIs it possible enable and disable a usb port via vba?
An example of using this would be if I had a light plugged in a usb port and the code would turn it on and off.
Or maybe is there s some device like <PC-Some Device-USB light > which can be controled by vba
Whenever I double-click a graph in a form that is being viewed it opens up MS Graph in edit form. This is confusing/ugly/etc and I don't want it to do that.
I tried adding some code to the double click event to make it do some other action (bringing up some graph modification tools I created), but as soon as those are closed MS Graph will then open up in edit form.
How to turn this off? It's incredibly unprofessional.
i am wanting to find some way of turning off the menus and toolbars in a startup macro and is it possible to turn off the warning messages that appear when appending or deleting rows in a table. many thanks
View 3 Replies View RelatedI have a multi-user db. There are actually 3 computers all on a windows network that access the db, which is located on my hard drive. The computers are in different offices.
I've asked the users to please close the db when they are leaving for the day - so that it does not remain open - and lock me out of design mode. But they sometimes forget and leave the db open.
When I come in in the morning (I'm the first one here) I sometimes have to walk to their offices and close the db manually.
Is there any way to close the app from my computer - so that all instances of the db are closed? Perhaps even a button somewhere with vba code that would do it?
Hi, I have a query with a 'many to one' join from a table of selected part numbers I want to look at which includes new part numbers with no current order numbers, to a master order table with all order numbers raised against all part numbers. The query returns null values for the new part numbers with no orders. This is what I want to see and the order numbers are stored as text.
I have converted these to numbers using CLng as I need use them in caluculations that only require adding or subtracting - (no DIV#0 issues). However, the nulls are returning '#Error' in the calculated fields which creates a type mismatch issue when filtering or setting other criteria. All fields used in the calculations are numeric.
I do not really have any knowledge of SQL, but is there a way to make the '#Error' values show as zero or something else I could work with.
Any help appreciated.
Thanks
I am using Office 2003. I tried entering this line of VB code :
Dim Db As Database
but got the following error :
Compile error : User defined type not defined
checked the net, which said to open the module window, go to Tools>References and check the DAO 3.06 box... but it said in Office 2003 i dont need to do this...Anyway i tried looking at the references but DAO 3.06 is not even there... pls tell me what to do
I've had a search and can't find anything along these lines...
I've got some code which plays about with reports and it looks awful when it's running - is there an equivalent of Excel's "Application.ScreenUpdating = False" functionality in Access (2000)?
Dave
Hi Guys,
I'm not sure this would be allowed as it could be maliciously abused, but what I want to do is turn of warnings when a user fires up my DB.
What currently happens is a user gets 3 pop up warnings in a row the first time they use the DB with essentially the same warnings and "do you want to run this" questions.
The next time the user runs the DB they only get one warning.
On another thread I was told how to turn warnings on and off within the database:
http://www.access-programmers.co.uk/forums/showthread.php?p=499732#post499732
'Turn warnings on & Hourglass on
DoCmd.SetWarnings False
DoCmd.Hourglass True
Code in routine that would generate warnings goes here.
'Turn warnings on & Hourglass off
DoCmd.SetWarnings True
DoCmd.Hourglass False
What I would like is some way to replicate the functionality for the DB. Is this possible?
Thanks in advance,
Keith.
How can I make the default zoom of the Report to 100%. Is there any way?
Thanks,
I have made two main menus, one for admin and one for users, I want to turn these into switchboards. When you open a form asking you to log in opens if you supply the right password it opens another form depending on your access rights depends which menu it opens, it all works perfectly but I want a home button, i.e. close all open forms, which would close the main menu, so I need to turn the main menus into switchboards, I have tried searching this place and I have also tried google although I may aswell have stuck my head out an open window and shouted for help!
Any way any help much appreciated
Regards
how to set the default in Access 2010 so that alternate row colors do not display when you create a new table, query or report.
View 3 Replies View RelatedWhat is the best way to turn all the menu bars and tools bars off and back on when a form opens and closes? Can you just loop through the numerated objects?
View 14 Replies View RelatedHow can I turn my DB into an Executable file, or "stand alone"...Id like to have the end users when opening the DB see only the forms and reports without the Access Background.
View 1 Replies View RelatedOK, usually I can figure these things out for myself, but I'm realy stuck on this one and any help would be appreciated
background: I work in a small scale pilot production line, and we take a series of measurements for every part that we make, each of which has a unique ID. Sometimes we need to take the measurements more than once, so that the data output from the measurement system (which it can append straight to an access table) has a part ID and a measurement number, the combination of which is unique (for reasons that I won't go into it is not possible to combine them into a single field, otherwise we would do this)
problem: The measurement system can be temperamental and sometimes sends the same record more than once, and It is horribly time consuming to go through and check manually
It occured to me that we could send the measurements to table1 (where they would be stored temporarily), and write a sub to go through each record in table1 in turn, compare the part ID and measurement number to the records stored in table2 (where they would be stored permanently), and append the record to table2 only if the part ID and measurement number combo has not already been taken, before moving onto the next record in table1 and doing the same thing
The part I just can't figure out is how to go through the records in turn and compare them, I can do the append and deletion using SQL, that's not a problem.
if anyone can point in the right direction I'd be realy grateful (or tell me if I'm barking up the wrong tree completely)
regards
Bogzla
Is there some way to make subdatashheets default to remove/off?
Thought options/datasheet/ might have a little button that defaults subdatasheets to off but to no avail.
Using Access 2010
How to turn on double-sided printing through code but I actually have the opposite problem and I can't find any solutions that have worked.
In order to be as green as possible, our printers are set up for duplex printing.
I have an Access 2010 database that creates discipline notices. This report, no matter what I try, will not print multiple notices on separate pieces of paper. Because they are discipline notices and are handed out to the associates, they must print on separate papers to maintain confidentiality.
Using Access 10 I am unable to turn off the alternate row color function for my report. The icon is on the toolbar, but is grayed out so I am unable to select it.
View 1 Replies View RelatedI have a report that in the Detail section on Format will change a record to a certain color based a criteria. (See VBA code below). I would like to put a text box control in the report footer to count the number of records that turn a certain color, this is what I have so far for the text box control -
=Count(IIf([PO Date]=RGB(0,255,255),True,Null)).
It returns a zero.
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
'Set the backstyle to normal (default is usually transparent)
Late_Ship.BackStyle = 1
If [Po Date] > ([Order Date] + 2) Then
PO_Date.BackColor = RGB(0, 255, 255)
[Code] ....
I’m new to Access and have been looking through a lot of the sample db,s very helpful, am I right in my conclusion that there is a lot of work being carried out in VB in the modules.
I’m reading all sorts of books at the moment and they are not going any ware near this area.
Is this the new 2003 program getting to grips:)
Hello,
I am getting an error with the Me function if present in modules. Is this because a module is Public?
How can I fix this problem and make the code run in a module?
Thank you.
This code runs an append query before closing a form named form1 and open another form named form2 using the c/n as linking criteria.
I am getting the error with Me.
I am trying to run this module from a menu bar.
thank you for you help.
Dim mydb As DAO.Database, MyRs As DAO.Recordset
Dim strCode As String
Dim strFilter As String
Dim stDocName As String
Dim stLinkCriteria As String
Set mydb = CurrentDb
Set MyRs = mydb.OpenRecordset("list")
stDocName = "form1"
stLinkCriteria = "[c/n]=" & "'" & Me![C/N] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
DoCmd.OpenQuery ("AppendHISTORY")
DoCmd.Close
DoCmd.OpenForm ("form1")
End Sub
Sorry I have to ask such a simple question. I haven't worked on Access for over 10 years.
How do I find out which modules is the startup? Thanks.
DanYeung
Hi guys, im working on a project whereby a Visual Basic module has been designed in MS Access to email out a RTF document attachment of reports to shift managers when they have hazard items not closed in their area. Im building an ASP front-end to the database and would like to incorporate a button to do the mailout, however i dont know how i can link it to fire the code when the button is pressed. Is it even possible?
Nath
Friends,
I need to place a vba code from a regular event in a form to a module so that when the form opens the function in the module is recalled using a macro.
How do I do this?
For example, I have the following code in the OnOpen event of a form:
Dim strInputBox As String, bytChoice As Byte
InputPoint:
strInputBox = InputBox("Please input the password.", "Password Required - Restricted Area! ")
If Len(strInputBox) > 0 Then
If strInputBox <> "***" Then
bytChoice = MsgBox("Wrong password" & vbNewLine & vbNewLine & "Do you want to try another?", vbExclamation + vbYesNo, "Warning")
If bytChoice = vbYes Then
GoTo InputPoint
End If
Else
DoCmd.OpenForm "Maintenance"
End If
End If
I would now like to place this code in a module and run it using a macro.
Any help? Thanks.
I have form called frmplant on open I select plant type from the combo box then there is a sub form called plantitem tbl subform this show's the plant under that type on a continuous form so the user enters the plant information then they have command button to open another form call frmpopupPlantService to log the service history of the plant item the user enters the service date and service notes I have text box call "add" this shows the next service due this is the value I want to add to plantitem tbl subform in the service due date box when frmpopupPlantService form is closed . This what I have tried
Code:
Me.add = [Forms]![frmplant]![PlantItemTbl subform]![ServiceDueDate]
[Forms]![frmplant].Requery
But I get error
run time error
you can't assign this value to a object
Here a sample of my database : shanetest.zip
I want to know the day name of a date. I am getting type mismatch 13 for this line
PrintingDateDayName = WeekdayName(Weekday(PrintingDate))
So this code is not right. This is my full code
Dim RegisterDate As Date
Dim PrintingDate As Date
Dim PrintingDateDayName As Date
RegisterDate = Me.txt_register_date
PrintingDate = RegisterDate + 180
PrintingDateDayName = WeekdayName(Weekday(PrintingDate))
If PrintingDateDayName = vbSunday Then
MSG1 = MsgBox("It's Sunday", vbOKOnly + vbInformation + vbMsgBoxRtlReading, "Clients Database")
Else
MSG1 = MsgBox("It's Not Sunday", vbOKOnly + vbInformation + vbMsgBoxRtlReading, "Clients Database")
End If