Go Back   Access World Forums > Microsoft Access Discussion > Forms

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 07-22-2014, 06:37 AM   #16
CJ_London
Super Moderator
 
Join Date: Feb 2013
Location: UK
Posts: 10,434
Thanks: 40
Thanked 3,367 Times in 3,262 Posts
CJ_London is just really nice CJ_London is just really nice CJ_London is just really nice CJ_London is just really nice CJ_London is just really nice
Re: Help creating duplicate record with specific fields blank.

Quote:
Also, the date formatting I made based off of your original post is not working well:

Public Function getDateText(ByVal field_name As Date) As String
Quote:
go about formatting my query for a Yes/No field
Yes/No,True/False and -1/0 are all the same thing which is numeric so I would just use the getnumeric function

__________________
CJ_London
_______________________
A little thanks goes a long way. If you have found this post useful, please tick the thanks button
CJ_London is offline   Reply With Quote
The Following User Says Thank You to CJ_London For This Useful Post:
pheidlauf (07-22-2014)
Old 07-22-2014, 07:24 AM   #17
pheidlauf
Newly Registered User
 
Join Date: Jun 2013
Location: Chicago
Posts: 42
Thanks: 20
Thanked 0 Times in 0 Posts
pheidlauf is on a distinguished road
Re: Help creating duplicate record with specific fields blank.

Quote:
Originally Posted by CJ_London View Post
Yes/No,True/False and -1/0 are all the same thing which is numeric so I would just use the getnumeric function
Fixed it for good this time (I think :O).

Code:
Public Function getNumericText(ByVal field_name As String) As String
    getNumericText = Me(field_name)
End Function

Public Function getStringText(ByVal field_name As String) As String
    getStringText = "'" & Replace(Me(field_name), "'", "''") & "'"
End Function

Public Function getDateText(ByVal field_name As String) As String
    getDateText = "#" & Format(Me(field_name), "mm/dd/yyyy") & "#"
End Function
I'm running all True/False fields through the getNumericText function.

pheidlauf is offline   Reply With Quote
Reply

Tags
button , copy , duplicate , form , reset

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Specific number of blank new record nofar Forms 9 06-23-2011 04:47 AM
Duplicate Specific Fields Only with Subform too Abdulkawi Forms 1 04-14-2011 07:25 AM
Help: Save, Duplicate Record cum auto del specific field for user to input record Crystallew Forms 1 06-26-2007 08:05 AM
Populate duplicate blank fields Ciaran_Enright Modules & VBA 2 11-25-2005 07:33 AM
How to duplicate a specific record skelley Forms 1 09-09-2000 07:11 PM




All times are GMT -8. The time now is 05:48 PM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Sponsored Links

How to advertise

Media Kit


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World