VBA Code For Showing Databasewindow
Mar 5, 2006Hi,
Within Access it is possible (under startup) to show or hide the databasewindow.
With which VBA code can I change this setting to visible = true .... or false?
:confused:
Hi,
Within Access it is possible (under startup) to show or hide the databasewindow.
With which VBA code can I change this setting to visible = true .... or false?
:confused:
Works great, but when I hit the number "3", (3 times in row) it will let me into the form. I want it to not let me in IF I don't know the password.
Where did I go wrong?
Private Sub Form_Load()
Dim pw As Variant
If InputBox("What is the password?", "Password") = "1" Then
Else
MsgBox "Invalid Password", vbCritical, "Sorry Charlie"
DoCmd.Close
If InputBox("What is the password?", "Password") = "2" Then
Else
MsgBox "Invalid Password", vbCritical, "Sorry Charlie"
DoCmd.Close
End If
End If
End Sub
I protect my code from people being able to read it by setting a password on the code from Tools > Properties, selecting the Protection tab and entering a password, and clicking "Lock Project"
Is there a way to write code that will remove that Lock Project check and check it back on?
I've looked through the Application.SetOption command and it doesn't seem to be one of the choices. It would be very helpful if someone knew how to do this.
Thanks
SHADOW
I have an unbound field that counts the number of records (=count(emplnumber)). When I open the form the value in the field is not there, if I click on the field the value appears.
It's almost like the field is being highlighted by the cursor and covering up the contents, but the cursor has it's focus set to another field.
Oh, the field is on the form footer if that matters.
Anyone know what I am talking about?
Thank you
:confused: hi ,,,
i have this Microsoft Application and i have unchecked the check box (Allow full menus ) in the starup ... So when ever i run the application i only get
the menu bars : File, Window, Help, AdobePDF
how can i get the other menu bars ?
any suggestions
thankx:o
Hi All,
I have 2 sets of fields, 1 for this week and 1 for last week.
I would like to change the background colour of this weeks fields to show either an increase (green) or a decrease (red) from last weeks figures.
Can anyone help me?
Thanks
Twin
Hello all,
I have a problem that is really giving me great headaches. I have had no success what so ever. My gratitude goes to anyone that can provide some insight.
I have two tables. One table for appointments and one table of all available time slots (ie 0930 is record 1, 1000 is record 2, 1030 is record 3 and so on).
If lets say there are records in the appointments table for eg today 01/06/2005 where there are two appointments (eg 0930 and 1000) I want to build a query that shows all the appointments that have not been used (so 0900, 1030, 1100,and son on). Adding to this, I need it to show these available timeslots for multiple dats (as the appointments table will have some appointments booked for the 01/06/05 and some for the 02/06/05 and some for eg 10/06/05).
I am aiming to implement this on a Active server page where the user selects the data and then the available appointments are displayed for that given date. However, I know that the query as descibed above is essential for this to be developed!
I have spent many hours trying to solve this with absolutely no success, so many thanks in advance to anyone that can help. Apologies for descibing the problem thoroughly.
Thanks
Ricky.
I have two database tables, one of information of members and one of staff. I want to do a query to show all members and staff that have the title of 'Mr' in the database.
There are only 5 staff details in my staff database at the moment, all with the title 'Mr'. There are 20 members details, 13 with the title 'Mr'. When i run the query i get only 8 names, 4 from the staff and 4 from the members.
The 4 staff ones i get are the 2nd, 3rd, 4th and 4th records.
The first record of the members field does not have the title 'Mr' and so it appears that this is blocking the first staff one to appear. And the members stop appearing after the 5th record too, so it appears they are stopped as there are no more staff records.
I hope this makes some sense to you, and if anyone could tell me how to get all the records to appear that would be great. Thanks.
Hi
I have a query which is made up of several other queries that total different fields (these are a base for a report) sometimes one of the queries will be empty and then the whole query is blank, how can I return 0 when there are no records to count in 1 query so that the results from the others still show?
Thanks
Hello..
This I think is easy, but I can't put my finger on it. I have a table of processes 12 of them. In the query I have them by date. What I want to do is to be able to show all 12 processes even if there is no info in them. I have a completed button, but if there is no info in the process the completed or not completed won't show up. The process is associated to an event. Hope this makes sense.
Any suggestions? I tried in the report to have a grouping, but if no information is present for that process it doesn't show up. I want the process to show up with or without info. So the end users can track the progress on a week by week basis.
Hopes this makes sense.
Thanks
Hi,
I have copied a form and changed the table it is linked to. however, now it just shows a blank screen, not any fields.
I have spent hours on this, please can somebody show me what I have not changed. i have attached the database.
thanks in advance
lee
Hi there,
I have a "minor" problem which most of you will probably have a laugh about :eek:
I have set up my Table / Form to have an image for each "item".
Now...when I add the image, it does not show up as the thumbnail JPG. It only appears as the image name.
So instead of seeing a picture, I see 1.jopg (example)
Can anyone help me with a correct hint?
Much appreciated
Chris
Hi
i am creating a knowledge base for IT Problems.
On my main form i have a combo box which has different options within it.
I have a second form.
I have linked the second form onto my main form using the subform function and set the second form to not visible on its properties.
Basically what i want to do is when i click the option 'Other' in my combo box i want the second form to be shown within my main form.
I have managed to do this when i click any option on the combo box but i dont know how to load it just by clicking on the 'Other' option.
Thanks
Gazza :)
How would I go about doing this: I need to show two different forms one after another. For example; a menu screen (1st screen) with a command button that will pop up another screen (2nd screen) for the user to enter details about themselves. After clicking on the command button (On the 1st screen) that screen to would hide but be brought back if they click cancel. (It's a bit like having a cancel button but it goes back to the main screen instead of closing the form.) Cheers
View 2 Replies View RelatedI accidently deleted the swithboard from the "forms"-area. I know it is still there, coz when I got to Database utilities|Switchboard Manager I can still see it. How can I get it back in the "forms area"
Thank u..
Stacey
Hello guys,
I have form with a button called process ,when I hit the button it select the column from oracle database tables and then it inserts the values in other oracle database table,so during this process ,I used docmd.hourglass true,but now I want to change to a message stating "Processing..." and after finishing the insertion it hides this message,is anyway to achieve this.
Please let me know asap.
Thanks
vsap
Hello
I've got the folowing sitation:
Mainform "KlantvolgsysteemB"
It's based on a field "projectnummers".
On this main form there's an unbound text box "Bericht" (not visible)
Also on this main form there is a subform named "Subformulier ContactactiviteitenBM"
It's possible to fill in a date on the subform "Subformulier ContactactiviteitenBM". This date is named AttentieDatum (Date/time). There is also a field "Attentie" (Yes/No)
My issue:
When the field "AttentieDatum" is equal to the systemdate and "Attentie" is True the unbound text box "Bericht" should become visible.
I've got the following code:
On the action After Update from "AttentieDatum" from the subform "Subformulier ContactactiviteitenBM"
Private Sub Attentiedatum_AfterUpdate()
Dim JaarNu, JaarToen, MaandNu, MaandToen, DagNu, DagToen, Attentie, Bericht AS Integer
JaarToen = YEAR(Forms!ContactactviteitenBM!AttentieDatum)
MaandToen = MONTH (Forms!ContactactviteitenBM!AttentieDatum)
DagToen = DAY(Forms!ContactactviteitenBM!AttentieDatum)
JaarNu = YEAR(date())
MaandNu = MONTH(date())
DagNu = DAY(date())
Forms!KlantvolgsysteemB!Bericht = Bericht
End Sub
And on the action On Current from the mainform "KlantvolgsysteemB"
Private Sub Form_Current()
Dim JaarNu, JaarToen, MaandNu, MaandToen, DagNu, DagToen, Attentie, Bericht AS Integer
Forms!KlantvolgsysteemB!Bericht.Visible = False
If IsNull (Forms!ContactactviteitenBM!AttentieDatum) Then
Forms!KlantvolgsysteemB!Bericht = Null
Else
JaarToen = YEAR(Forms!ContactactviteitenBM!AttentieDatum)
MaandToen = MONTH (Forms!ContactactviteitenBM!AttentieDatum)
DagToen = DAY(Forms!ContactactviteitenBM!AttentieDatum)
JaarNu = YEAR(date())
MaandNu = MONTH(date())
DagNu = DAY(date())
Forms!KlantvolgsysteemB!Bericht = Bericht
IF Attentie = True AND JaarNu = JaarToen AND MaandNu = MaandToen AND DagNu = DagToen
Then Forms!KlantvolgsysteemB!Bericht.Visible = True
End If
End Sub
Can anybody help me?
Sorry for my English. I'm from holland :o
hi all,
i have question about showing last record in a form. i have 2 table, ra and repair tables. each ra_id is consists of many repair. each repair have time and date stamped. I want to show in tabular view all of the ra records including the last update of each repair per ra_id in a form. When I select some fields in ra + time in repair table, the form showing only records that has repairs ONLY, but not all records. And also display time BUT not the last update, instead showing ALL repairs. can any one help, if i want to show all records plus time but ONLY the last update on the repair. I don't know much vba, so please tell me what to do in macro or expression builder????
We have a MS Access 2000 database that our Mgmt uses for reporting. We have a new manager that just started. Most of the computers we have run on Windows 2000 and some on Windows XP. So yesterday, I put the icon on his computer and double clicked and nothing came up. No switchboard. (He has Windows XP) But if I hold the shift key down and double click on the icon all the tables, reports, and queries show up and they all work. Hmmm. It runs fine on every other computer that has XP. It's just this one stupid pc. Anyone out there have any ideas?
View 1 Replies View Relatedi need to size a form so that it does not fill all the window, i have tried enabeling the min and max buttons but they will not display for some reason, i changed the borderstyle to sizable and the controlbox to yes the min and max buttons are enabled , but still not showing the min and max buttons, the close button shoes and thats it? i am running 2010.
View 3 Replies View Relatedhow do I set up supplier name in the order table like the example in the
northwind database?
what I mean is set supplier ID so that it shows combo box with names instead of numbers.
Hi guys and Girls
I have a txt box on a report which should show comments..
In the background table the field this txt box is bound to has a data type of memo. Yet the txt box on the report stops showing any more than 255 characters! any clues? I know 255 is the field size set for my Txt fields but memo fields should be able to display 65000000000000000 trillion characters with no problems.
When I look at the table the memo field has all the txt in it, it just wont display all the txt on the report.
Thanks for any help guys.
I have got a db when I enter a new client in the client form it saves it in the table but when I return to the form the client I have just entered is still there so I cant enter a new client it does'nt clear the text in the text box can anyone help
Thanks
Hello
I have a problem that is really giving me great headaches. I have had no success what so ever. My gratitude goes to anyone that can provide some insight.
I have two tables. One table for appointments and one table of all available time slots (ie 0900 is record 1, 0930 is record 2, 1000 is record 3 and so on).
If lets say there are records in the appointments table for eg today 01/06/2005 where there are two appointments (eg 0930 and 1000) I want to build a query that shows all the appointments that have not been used (so 0900, 1030, 1100,and son on). Adding to this, I need it to show these available timeslots for multiple dats (as the appointments table will have some appointments booked for the 01/06/05 and some for the 02/06/05 and some for eg 10/06/05).
I am aiming to implement this on a Active server page where the user selects the data and then the available appointments are displayed for that given date. However, I know that the query as descibed above is essential for this to be developed!
I have spent many hours trying to solve this with absolutely no success, so many thanks in advance to anyone that can help. Apologies for descibing the problem thoroughly.
Thanks
Ricky.
I have a query calculating the sum of checked boxes of field 'A' ('letters sent') and the sum of checked boxes of field 'B' (letters received). My sum field is counting the boxes that are checked but showing the values with a negative sign in front?? How do I correct this? Also - could I create an additional field in this query to calculate the percentage% (success rate) #B's checked/#A's checked?
View 4 Replies View Related:p Hello,
I am wondering if anyone can help me create a query (which is used as a basis for a report) using a criteria which is clever enough to know that if all fields are have an N (no) that a report should not be generated - but with anything else e.g. all Y's or a mixture of Y's and N's that a report will be printed. There are 6 columns where there could be a Y (yes) or an N (no) and I would really like to know if this is possible in access??
Thanks.