User Profile

Collapse

Profile Sidebar

Collapse
jtgarrison
jtgarrison
Last Activity: Mar 3 '11, 03:12 PM
Joined: Jan 13 '10
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Ok....what about looping through the records that are going to be added? It will not be the same number of records each time the process is run.
    See more | Go to post

    Leave a comment:


  • It would need to get a count of the the records it imported, loop through them and give it a number (voucherNumber) .
    See more | Go to post

    Leave a comment:


  • jtgarrison
    started a topic How to append Records to a table via VBA?

    How to append Records to a table via VBA?

    I'm moving a database from an Access backend to a SQL Server 2005 backend.

    What I need to do is to append the number of records that get pulled in from a table and increment the voucherNumber field to the next available one.

    The code below was originally written in DAO.

    Code:
      Dim RecordCount As Integer
        Dim strSQL As String
        Dim db As Database
        Dim rec As New ADODB.Recordset
    ...
    See more | Go to post

  • Thanks for the info...will try it out when I get a few minutes.
    See more | Go to post

    Leave a comment:


  • The same...it created the file.

    Here's the complete code...
    Code:
    Private Sub cmdGenerateFile_Click()
        Dim strExportFileName As String
        Dim strPositivePayFileName As String
        Dim strPositivePayExportFileName As String
        Dim blnIncludeYear As Boolean
        Dim blnUseBankNaming As Boolean
        Dim strBankAccountNumber As String
        
        blnUseBankNaming = DLookup("UseBankNamingonPositivePay",
    ...
    See more | Go to post

    Leave a comment:


  • Neo -

    It is....I have msgboxes that shows that it is.

    Funny thing is...when I change to parentheses, it works, but not brackets, which is what I need.
    See more | Go to post

    Leave a comment:


  • Using VBA to Export a CSV File To Include Brackets

    I need to export a file through VBA, but as part of the file name is to include a Date/Time stamp in brackets.

    Here's what I have:
    Code:
    strExportFileName = "C:\My Documents\" & strPositivePayFileName & "[" & Format(Date, "mmdd") & Format(Time, "hhnn") & "].csv"
    and the Export Code:
    Code:
    DoCmd.TransferText acExportDelim, "Positive Pay Export
    ...
    See more | Go to post

  • Stupid question - this will give me the beginning of the the current week, but how do I get the previous week's beginning and end?
    See more | Go to post

    Leave a comment:


  • Find The Week Begin and End Date Based On Current Date

    I apologize in advance if this has been asked for or if I'm missing somithing obvious, but I have a form that I want to auto populate the week beginning and week ending date based on the current week. I'd also like to be able to selcect (via Option Group) last week and it give me the week begin and end date.

    Thanks in advance.

    Jeff
    See more | Go to post

  • jtgarrison
    started a topic Formatting a Fixed With Query Column

    Formatting a Fixed With Query Column

    I have a field in SQL that contains a Currency amount, which will be used for an export. It needs to be 13 characters long, preceded by 0 then the dollar amount, without the decimal point.

    The field name is DOCAMT. To get the full amount, I'm sure that I need to multiply the currency by 100, but how do I get the dynamic part of the field to be 0's.

    Since this will be an export, it would need to be a query instead of...
    See more | Go to post

  • This is what I have:

    Code:
    Option Compare Database
    Public Enum OfficeAppName
    ' enums always start from zero, unless otherwise specified
    ' for demonstration purposes (on the worksheet), start from 1
       Outlook = 1
        PowerPoint = 2
        Excel = 3
        Word = 4
        Publisher = 5
        Access = 6
    End Enum
      
    Function IsAppRunning(appName As OfficeAppName) As Boolean
    ...
    See more | Go to post

    Leave a comment:


  • I placed the code in a module and put the msgbox IsAppRunning(Ou tlook) and go a Compile Error: ByRef argument type mismatch.
    Any ideas?...
    See more | Go to post

    Leave a comment:


  • jtgarrison
    started a topic Determine if Outlook Is Open - If Not, Open It

    Determine if Outlook Is Open - If Not, Open It

    Is there a way to tell if Outlook is open before sending a message and open it if it's not?

    I have some old code that I have been using:

    'Determine If Outlook Is Open. If Not, Open.
    Set objOutlook = GetObject(, "Outlook.Applic ation") ' Determine if Outlook is open.

    If Err <> 0 Then
    Call Shell("C:\Progr am Files\Microsoft Office\OFFICE12 \OUTLOOK.EXE")...
    See more | Go to post

  • jtgarrison
    replied to Pulling User Environment Settings
    Actually, I figured it out....It's Environ("userpr ofile")&"\"&env iron("username" )&"\" &"My Documents".

    Thanks.
    See more | Go to post

    Leave a comment:


  • jtgarrison
    started a topic Pulling User Environment Settings

    Pulling User Environment Settings

    I'm trying to pull some user settings in VBA, but I'm not quite sure what the correct syntax is.

    I'd like to pull the logged on User Name's My Documents, no matter what version of Windows they are using...XP, 7, or 2003. I think the syntax is Environ("userna me"), but how do I get Username\My Documents regardless of what version?

    Thanks.
    See more | Go to post

  • Thanks!

    Something so easy cost me a couple of hours searching...
    See more | Go to post

    Leave a comment:


  • jtgarrison
    started a topic How to call a form name from a lookup table

    How to call a form name from a lookup table

    I have a database front end that stores variables based on what the user is doing. What I want to do is requery a form, but the form is being looked up from the table.

    Ex.
    Code:
    Dim strFormName as String
    
    strFormName=dlookup("FormName","tblCurrentValues")
    
    if CurentProject.AllForms(strFormName).IsLoaded Then
        Forms!strFormName.Requery
    ...
    When I run it, I get...
    See more | Go to post
    Last edited by NeoPa; Jul 1 '10, 03:54 PM. Reason: Please use the [CODE] tags provided.

  • jtgarrison
    started a topic Importing CXML Into Access

    Importing CXML Into Access

    All -

    Is there a way to import CXML into Accesss? I know that you can import XML,, but I haven't been successful trying to import CXML. I'm not sure if there needs to be transform or not.

    Thanks.

    Jeff G
    See more | Go to post
No activity results to display
Show More
Working...