473,414 Members | 1,980 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

Message Popup based on ID

I have a section of my app where I want to display a message detailing the #
of open issues, I want this to popup when they login and give them a choice
to look at the issues or continue on. This will be basd on thier workID. I
have a separate form for issues where I will query based on thier ID.

What do I need to look at to make this work?

TIA

Gerald

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ccess/200608/1

Aug 24 '06 #1
4 1256
You can use DCount to get the count of open issues So you could have
code in your startup form that runs when it opens that gets the count
of open issues with DCount, and if it's non-zero, show a Msgbox asking
if the user wants to look at the open issues. You can easily use the
MsgBox function for it.

dim intReply as Integer
intReply=MsgBox("Would you like to look at the open
issues?",vbYesNo,"Open issues exist")

if intReply=vbYes Then
DoCmd.OpenForm "frmSomeForm"...
else
DoCmd.OpenForm "fromOtherForm"
End If

Aug 24 '06 #2
Here is what I have so far.

DoCmd.Close acForm, "Splash", acSaveNo

strSQL = "SELECT DISTINCT [Maint Records].Tech"
strSQL = strSQL & " Count([txtTechTicket]=[Maint Records].Tech) "
strSQL = strSQL & " ((([Maint Records].Tech)=[txtWorkID]))" & ";"

Debug.Print txtTechTicket

MsgBox ("You have " & [txtTechTicket] & " tickets open. Do you want to
work tickets now?"), vbQuestion, "Open Tickets"

The problem I am having now is that it does not look like my query is
executing. i have one record in the table that will match, but txtTechTicket
is showing 0. What am I missing?

pi********@hotmail.com wrote:
>You can use DCount to get the count of open issues So you could have
code in your startup form that runs when it opens that gets the count
of open issues with DCount, and if it's non-zero, show a Msgbox asking
if the user wants to look at the open issues. You can easily use the
MsgBox function for it.

dim intReply as Integer
intReply=MsgBox("Would you like to look at the open
issues?",vbYesNo,"Open issues exist")

if intReply=vbYes Then
DoCmd.OpenForm "frmSomeForm"...
else
DoCmd.OpenForm "fromOtherForm"
End If
--
Message posted via http://www.accessmonster.com

Aug 25 '06 #3
Put a break in there and see what the value of strSQL is. Judging by
the looks of it, I doubt it's going to return anything.

gjameson via AccessMonster.com wrote:
Here is what I have so far.

DoCmd.Close acForm, "Splash", acSaveNo

strSQL = "SELECT DISTINCT [Maint Records].Tech"
strSQL = strSQL & " Count([txtTechTicket]=[Maint Records].Tech) "
strSQL = strSQL & " ((([Maint Records].Tech)=[txtWorkID]))" & ";"

Debug.Print txtTechTicket

MsgBox ("You have " & [txtTechTicket] & " tickets open. Do you want to
work tickets now?"), vbQuestion, "Open Tickets"

The problem I am having now is that it does not look like my query is
executing. i have one record in the table that will match, but txtTechTicket
is showing 0. What am I missing?

pi********@hotmail.com wrote:
You can use DCount to get the count of open issues So you could have
code in your startup form that runs when it opens that gets the count
of open issues with DCount, and if it's non-zero, show a Msgbox asking
if the user wants to look at the open issues. You can easily use the
MsgBox function for it.

dim intReply as Integer
intReply=MsgBox("Would you like to look at the open
issues?",vbYesNo,"Open issues exist")

if intReply=vbYes Then
DoCmd.OpenForm "frmSomeForm"...
else
DoCmd.OpenForm "fromOtherForm"
End If

--
Message posted via http://www.accessmonster.com
Aug 25 '06 #4
I get this right after the last strSQL line.

SELECT DISTINCT [Maint Records].Tech Count([txtTechTicket]=[Maint Records].
Tech)

Here is the query I made in Query.

SELECT DISTINCTROW Count([Maint Records].Tech) AS txtTechTicket, [Maint
Records].Tech
FROM [Maint Records]
GROUP BY [Maint Records].Tech
HAVING ((([Maint Records].Tech)=[txtWorkID]));

This is counting ok.

ManningFan wrote:
>Put a break in there and see what the value of strSQL is. Judging by
the looks of it, I doubt it's going to return anything.
>Here is what I have so far.
[quoted text clipped - 28 lines]
DoCmd.OpenForm "fromOtherForm"
End If
--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ccess/200608/1

Aug 25 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Obantec Support | last post by:
Hi i leached some code and strung together a popup i need for a page with 5 help buttons. Now i could use 5 scripts and pre-load the values but i would rather get a better understanding of how...
3
by: Dan | last post by:
First, I'm sorry if this question has been asked too many times. I'm new to this news group. The question has to do with the use of popup windows in a web page. I have heard that popup windows...
1
by: MJEASSOC | last post by:
I need some help with closing a popup window. I'm making an online portfolio, that has one base page with text and thumbnails. When a user clicks on a thumb, a new window opens containing a larger...
24
by: jonathon | last post by:
Hi all, I have a web app with a popup window for entering data. I don't want to access the web every time this window is opened, as most of the app is AJAX. But I can't figure out how to open...
23
by: Markus | last post by:
Hi, i have this problem: Sometimes, i can't reproduce, if i click on an small image on the website, the popup _AND_ an other Tab in firefox open. Here are the linkcode: <div...
6
by: tshad | last post by:
I am trying to set up a Javascript popup box that has a way of sending back a message to asp.net on how to process some data. At the moment I am just doing: ...
4
by: Macbane | last post by:
Hi, I have a 'main' form called frmIssues which has a subform control (named linkIssuesDrug) containing the subform sfrmLink_Issues_Drugs. A control button on the main form opens a pop-up form...
3
by: cmo | last post by:
Well I hope I this isn't too nebulous of a problem. The problem I currently have is this: I have a button in a form that opens up a javascript/css poup that has an input field and two ahref links...
11
by: V S Rawat | last post by:
using Javascript, I am opening a web-based url in a popup window. MyWin1=Window.Open(url, "mywindow") There is a form (form1) in the url in that popup window, I need to submit that form. ...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.