Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. Marco123

    Excel VBA - Copying button down multiple rows whilst keeping relative positioning

    Hi all, I have several buttons in a row on a spreadsheet that I am trying to copy down multiple rows in VBA. I know how to copy a button in VBA with the following code: ws.Shapes("Button 1").Copy ws.Range("J10").Select ws.Paste From this code, it is easy to loop it to copy down the button...
  2. Marco123

    Automatically determine If statement from multiple conditions sele

    Yeah that’s true, if my model went into a live trading environment having no conditions selected would be hazardous! Think I’ll put in some clause to give a warning if no conditions are selected.
  3. Marco123

    Automatically determine If statement from multiple conditions sele

    Thanks for your answer. I tested it and it is actually nearly correct except for one tiny thing. If the btrade boolean is initially set to false, then it will always remain false unless the bFunctionCondition1 is selected, and is true. This is because if the btrade is initially set to false, it...
  4. Marco123

    Automatically determine If statement from multiple conditions sele

    Hi All, I’m trying to code an automated trading system that will perform a trade if certain conditions are met. Assume there are 5 conditions, and the user can select any one, two, three, four or five of the conditions together. This means the user could select any number of conditions, and any...
  5. Marco123

    Continuously updating chart for stock prices

    Unfortunately it’s not free to download that backtesting spreadsheet shown in the clip. Moreover, even if I did there is still a chance the VBA code could be password protected. Though, I have tried at a very basic level pretty much what I mentioned in my previous post and it appears to work.
  6. Marco123

    Continuously updating chart for stock prices

    Hi All, I am trying to create a chart in Excel VBA that continuously updates with (historical) stock prices and P&L for backtesting a trading strategy. The user will be able to see the chart update i.e. the graph moving up or down and P&L change accordingly. Essentially, I would like to...
  7. Marco123

    DAO vs ADO for running sql from external DB

    It's actually not that I've got that many tables, it's that I need to create and delete temporary tables 1000's of times. Thankfully, it's worked so far.
  8. Marco123

    DAO vs ADO for running sql from external DB

    Thanks for the ideas but I think for what I’m doing, this method is sufficient. Essentially, I’m only really using the secondary database for doing calculations, creating, using and deleting temporary tables. I need to do the same series/steps of calculations 1000’s of times, and if Access...
  9. Marco123

    DAO vs ADO for running sql from external DB

    Hi All, As I am manipulating huge volumes of data using VBA and SQL, the Access database I’m using (the master database) becomes prone to exceeding it’s 2gb limit. In order to solve this problem, I am trying to do most of the manipulations/calculations in an external (secondary) database, and...
  10. Marco123

    Access SQL Conditional Join

    Thanks for the replies. It appears, then, that Jet SQL does not actually contain the functionality to do conditional joins. I'll do something along the lines suggested above and I quite like the code provided by lameid. As it happens, I work in the energy trading industry too and the winter...
  11. Marco123

    Access SQL Conditional Join

    Hi All, I am trying to run a query that joins 2 tables, however, the joins will be different depending on certain criteria. I have 2 tables as follows: TblMonth Month MonthlyTotal Dec-08 Jan-09 Feb-09 Mar-09 etc TblSeason Season SeasonalValue Winter09 200 Summer09...
  12. Marco123

    UNPIVOT in Access SQL?

    Thanks, does just the job.
  13. Marco123

    UNPIVOT in Access SQL?

    Hi, Is it possible to use the UNPIVOT function in Access SQL? I have a table with 5 columns (Type, Category, Profit, Revenue, Cost) as shown below: Type Category Profit Revenue Cost A Small £150 £200 £50 A Medium etc A Large B Small B Medium B Large C...
  14. Marco123

    FileLen(Currentdb.Name) not updating when code is running

    Thanks but unfortunately it didn't work. I think the issue is definitely PC related as it works absolutely fine on my home PC, but I just can’t get it to work on my work PC. Looks like I’ll just have to work around it….
  15. Marco123

    FileLen(Currentdb.Name) not updating when code is running

    The code is actually a rather large piece of code. The weird thing is, though, that it actually works on my home PC (as opposed to my work PC). The only differences being that my home PC has a higher spec, and is not running a monster SQL query that connects to several linked oracle tables...
  16. Marco123

    FileLen(Currentdb.Name) not updating when code is running

    Hi all, I am having problems using the filelen function to determine the size of a database while the code is running. I have an Access database that is performing numerous calculations 1000’s of times with tables/temporary tables etc. The problem is that eventually Access exceeds it’s 2gb...
  17. Marco123

    SQL Query - Shifting Rows Up for certain fields

    Yes, there will only be one record/row for each date.
  18. Marco123

    SQL Query - Shifting Rows Up for certain fields

    Hi BigRed1212, in theory it would be possible but if I have more rows and columns, the table could potentially become very large.
  19. Marco123

    SQL Query - Shifting Rows Up for certain fields

    It’s not actually a database, I’m initially importing a worksheet from an excel file into the database in order to make the manipulation. Easy to do in vba, but quicker if it’s possible in SQL when you have huge volumes of data.

Part and Inventory Search

Back
Top