Search results

  1. S

    how to break a long piece of code into subroutines

    HI. I have written a lot of pages of code and since I was new to VBA, and I didn't take inot account things like debugging :).....I would like to break it down inot subroutines. The following piece of code is a small example It creates the lrow integers....and the Role array that are used...
  2. S

    storing and pasting a jpg

    Hi. I am writing code for a button in an Access DataBase that collects data from the database and creates an excel spreadsheet from the information. I would like to put a jpg of the company Logo on the spreadsheet....so I was wondering it there is a way to store a jpeg or a picture in the...
  3. S

    help with chart for loop

    Hi. I need to scroll throught a few charts on a page and set the max value of any of the charts to be the max scale of all the charts. I have used the following VBA code and it doesn't work. The mymax value doesn't seem to record the maximum value of any graph. Any help....especially if it...
  4. S

    cells as range

    Hi Could someone please help me with the syntax of specifying a range throught the use of excel cells... with access vba for example, something like this. Range(cells(2, 4) & ":" & cells (10, 10)).select I want to do this so that I can add intergers to teh Column number and move the range...
  5. S

    integer equal value of another integer

    Hi. I am trying to get intSus be equal to the value of intDown in the following code and I don't know why it won't pass the value on . Any help would be greatly appreciated :) Thanks Steve Dim intDown as integer Dim intSus as integer intDown = 1 intSus = 1 Do...
  6. S

    filling and using arrays

    Hi. I am having trouble getting data into an array from Access VBA in excel. I have used this code to get the data in.......but it keeps giving an error. I have tried playing with it but it won't work :( Dim Role() As Variant Dim lrow As Long Dim i As Long With Sheets("Sheet1") lrow =...
  7. S

    concatenation as variable name

    Hi. I would like to assign the value of a column of cells to a variable with a different number on the end as it moves down the rows. Dim No as integer No = 1 Sheets("Sheet1").Select Range("J1").Select Do "ROLE" & No = Activecell.value <--------------- This is the line that gives me an...
  8. S

    using arrays in loops.....maybee :)

    Hi. I have written a lot of pages of code and I have hardcodded all the variable names in.....now I have to change it to use outputs from the database which I have printed into a column in excel. I think this can be done using arrays but I don't know much about them Say the output that I have...
  9. S

    outputting values from table to excel.

    Hi. I have a table in my database called Roles, and I have a column called RoleID which is the primary key for the table. I would like to print the different Roles listed in this column to column A of an excel sheet. How would I go about this in VBA ? Thanks heaps for any help. Steve
  10. S

    filter column

    Hi. I am manipulating Excel throught access VBA and I was wondering if there is there a way to filter a column into just the unique cells and not have any repeated. I have attached a file and the in Column A there is 4 names repeated many times...........I would like to write some code so that...
  11. S

    storing address of active cell

    Hi. This might be a silly question but I'm using access VBA and I want to record the position of the active cell at certain point of my program........how can I store this addresses........ ie....will this make rngAdd equal to the position of the active cell at the moment, so I can store it...
  12. S

    Saving databse

    Saving database Hi. I need to add a button to one of the forms of my database that can save all the tables and stuff in the data base when u hit it and then with the click of another button the whole data base can be restored to that point. Could someone please give me an idea how this type of...
  13. S

    hiding excel manipulations and showing a progress bar

    Hi. When a user hits a button to format an excel report that is generated by my database i would like to be able to set excel to do it invisibly and to have some sort of progress bar or something to just let the user know that it is doing the formatting in the background.....I know how to make...
  14. S

    Searching title

    Hi. Firstly i would like to say how great the board is......I would have been stuck doing quit a few things without the search function and all the knowledge on the here :) I am trying to copy and paste certain charts depending on what is in the chart title This is part of a lot bigger code...
  15. S

    finding newest timestamped file

    Hi. I need to write some code in access VBA to find the newest timestamped excel file in a directory....( say the file is called myname(date)(time).xls)..... and then make a copy of it and rename it to say yourname.xls. Thanks for any help Steve
  16. S

    Problems ending a loop

    Hi. This code is to take a excel file...... which has a lot of of sheets called chart1, chart2 etc which have charts on them ...then sheet1 -3 at the end. My code coppies all the sharts and puts them on the front pare that I have created ok, but it gets an error and won't stop the look when it...
Back
Top Bottom