After opening and clicking on the popup calendar command control
button, "fdlgCal"; I click on a given date. The date is suppose to
then appear in a date field next to the control. Instead, I get the
following error:
"Microsoft Office Access
The expression On Click you entered as the event
property setting
produced the following error: The expression you
entered has a function
name that Microsoft Office Access can't find.
*The expression may not result in the name of a macro,
the name of a user-defined
function, or [Event Procedure].
* There may have been an error evaluating the function,
event, or macro."
Every thing use to work. My fear is that I changed one thing to many
during the process of debugging my whole application, and ended up
breaking this function.
Below is a description of how I have things set up:
1. I have a form called: "Employee"
2. It has a date field with the Control Source/Name: "startdte"
3. Next to this field is a calendar button named "Command100 " with
an On Click Event Procedure written as follows:
"Private Sub Command100_Clic k()
On Error GoTo ErrLine
startdte = CalendarDlg(sta rtdte)
ExitLine:
Exit Sub
ErrLine:
Resume ExitLine
End Sub"
4. Under my list of Modules; I have a module called "basCalDlg"
with the following Visual Basic Code:
"Option Compare Database 'Use database order for string comparisons
Option Explicit
Private Const cCalendarDialog = "fdlgCal"
'Const cModule = "basCalDlg"
Public Function CalendarDlg(Opt ional ByVal vPassedDate As Variant) As
Variant
'
' This is the public entry point.
' If the passed in date is missing (as it will be if someone just
opens the Calendar form),
' start on the current day. Otherwise, start with the date that is
passed in.
On Error GoTo ErrLine
Dim vStartDate As Variant
' If they passed a value at all, attempt to use it as the start
date.
vStartDate = IIf(IsMissing(v PassedDate), date, vPassedDate)
' OK, so they passed a value that wasn't a date. Just use today's
date in that case, too.
If Not IsDate(vStartDa te) Then vStartDate = date
DoCmd.OpenForm FormName:=cCale ndarDialog, WindowMode:=acD ialog,
OpenArgs:=vStar tDate
' You won't get here until the calendar dialog is closed or hidden.
'
' If the calendar dialog is still loaded get the final chosen date
from the form.
' If it isn't, return Null.
If IsFormOpen(cCal endarDialog) Then
CalendarDlg = Forms(cCalendar Dialog).Value
DoCmd.Close acForm, cCalendarDialog
Else
CalendarDlg = IIf(IsDate(vPas sedDate), vPassedDate, Null)
End If
ExitLine:
Exit Function
ErrLine:
Resume ExitLine
End Function"
John 0 1774 This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Ima Lostsoul |
last post by:
I cant seem to set the date on the calendar control. What i want to
happen is have a form pop up when a button is clicked (have that part of
course). This for has a calendar control on it. I have the code to
pass the date selected back to the original form working just fine. I
want to have the calendar start with whatever the current date is as the
selected date -or- a specificed date passed to the form (by a global
variable) based on...
|
by: JingleBEV |
last post by:
Hi all,
I have a masked text control that would return a date in string format via
the mask property like:
"9/23/2004"
and i have a calendar control that would pop up when I click a command
button, I know the masked text control always returns a valid date. How do I
code in the command click to highlight the correct date on calendar control?
|
by: Charles |
last post by:
Hello,
I would like for my users to have a calendar control
only when needed. IE button click for the control to
appear and then once the date is selected. Populate a text
box and the calendar control then is invisible.
How do I make the calendar control pop up over other
control in a asp.net c# environment?
Charles
|
by: Robert Ladd |
last post by:
Hi,
I'm trying to disable the asp.net calendar control from a javascript
function, but it doesn't disable the doPostBack.
To simplify the situation, assume a page with 4 controls. A dropdownlist, a
calendar control, a textbox and an update button. What I'm doing is
initially setting the button to disabled, the other 3 controls are enabled.
If any data is entered in the textbox, I want to disable the dropdownlist
and the calendar...
|
by: Kurt Schroeder |
last post by:
I am trying to add a link button to a calendar.
this is a simple example:
Private Sub Calendar1_DayRender(ByVal sender As Object, ByVal e As
System.Web.UI.WebControls.DayRenderEventArgs) Handles Calendar1.DayRender
If e.Day.Date = Now.Date Then
Dim lbtntemp As New LinkButton
lbtntemp.Text = "go here"
lbtntemp.ID = "thsLnk"
e.Cell.Controls.Add((lbtntemp))
End If
| |
by: Peter |
last post by:
I have a dilemna. Currently I have created a custom calendar webcontrol that a user can
select and will dump the date along with some specialized information set in the tooltip.
It actually is working great. However I am having the same second thoughts about the
control as everyone else because of all the real estate it takes up so I would like to
add a button to alternately hide/display the calendar control. The only problem is that
if I...
|
by: =?Utf-8?B?UGFycm90?= |
last post by:
I applied the following Ajax code in my web page which has a calendar control
to keep my page from completely reloading everytime something was changed.
<atlas:ScriptManager ID="ScriptManager1" runat="server"
EnablePartialRendering="true"/>
<atlas:UpdatePanel runat="server" ID="UpdatePanel1" Mode="Conditional">
<ContentTemplate>
After inserting this code, my calendar stopped working in that if I clicked
on a date, nothing would...
|
by: Sreenath Rao Nellutla |
last post by:
Hai all,
I am trying to create dropdown calendar control with HTML input control by writing JavaScript. But while executing I am getting the error as "Error on Page" on the status bar of the browser. I wrote the following code in the HTML code for the web form:
<%@ Page language="c#" Codebehind="WebForm2.aspx.cs" AutoEventWireup="false" Inherits="calendar.WebForm2" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>...
|
by: pavanik |
last post by:
hey this is pavanik,
i had created a pop up calendar control.it is working properly.
but the problem is while i click on the button the calendar is displaying but if iam not selecting any date in the calendar(when i click on the page),that calendar must be invisible,but it is visible .
I had taken a textbox,button,calendar control.
when i click on that button the calendar must be displayed.that...
|
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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 then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |