Search results

  1. B

    Update current record with next record value

    Many Thanks Arnelgp, forgot to mention I'm trying this in SAS. Somehow SELECT TOP 1 doesn't work out here. Any clue how to adjust this? Thanks.
  2. B

    Update current record with next record value

    Hi all, I want to identify the time frame of a agent's job. For example Agent 081 had a task aaa from 202012-202104, then it switched to task vvv from 202104 until now 202102. I found this code: data want; recno=_n_+1; set Task_times end=last; if not last then set...
  3. B

    Solved Get first observation of dataset

    Hello all, how can I get the first appearance of this dataset via SQL? 202012 0821 Ein 202106 0821 Mehr Thank you in advance. Kind regards, Ben
  4. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    Thank you, that was the missung point. You made my day :) Regards, Ben
  5. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    This also doesn't work :( sht.Range(Cells(2, 3), Cells(" & lastrow_BD & ", " & lastcolumn_BD - 1 & ")).Select
  6. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    I replaced it by sht2.Columns("C:C").Select now this works. However the select statement later on makes issues: oExcel.Range(Cells(2, 3), Cells(" & lastrow_BD & ", " & lastcolumn_BD - 1 & ")).Select or sht.Range(Cells(2, 3), Cells(" & lastrow_BD & ", " & lastcolumn_BD - 1 & ")).Select...
  7. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    It opens both Excel files out of Access. I'm using this: Dim oExcel As Object Dim oBook As Object Dim oBook2 As Object Dim lastcolumn_BD, lastrow_BD As Long Dim lastcolumn_BD2, lastrow_BD2 As Long Dim sht As Object Dim sht2 As Object Set oExcel = CreateObject("Excel.Application")...
  8. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    Thank you for the feedback. Unfortunately your proposed changes doesn't work out yet. I found out that this explicit code makes issues: It calculates the lastrow and lastcolum but breaks at the select statement: lastrow_BD = sht.Cells(sht.Rows.Count, "A").End(xlUp).Row lastcolumn_BD =...
  9. B

    Solved Method 'Cells' of object '_Global' failed in Excel session opened via Access

    Dear all, from time to time this code doesn't run giving the error message: Method 'Cells' of object '_Global' failed It opens both Excel tables, but it fails to insert a column. Every help is much appreciated. Thank you. Regards, Ben Public Sub Format_BD_Excel() 'Get all Excel files in...
  10. B

    Recordset Operation

    I was handling with this for two weeks. A suitable matching key is missing. On the one hand I got a data based on reporting months on the other hand data based on time periods. Can't avoid duplicates, at least I could convince a colleague that's not possible. At the end 2 weeks waste of time...
  11. B

    Recordset Operation

    As a next step I have to take the period information and replace.it with the above record. Afterwards I could delete the marked recordset. TA-1012 cihazımdan Tapatalk kullanılarak gönderildi
  12. B

    Recordset Operation

    Hi Mark, Thanks for the hint. But I need it in a program at the end. It has to run automatically every month. TA-1012 cihazımdan Tapatalk kullanılarak gönderildi
  13. B

    Recordset Operation

    Thank you but it still doesn't work. Booking Costs Period Dupl edited BC 222 22018 BC 76867 22018 AZ 34132 102018 AZ 41234 102018 MK 43214 32018 x MK 523 32018 MK 54134 32018 no current record error message jumping at .Movenext
  14. B

    Recordset Operation

    Period is a text field TA-1012 cihazımdan Tapatalk kullanılarak gönderildi
  15. B

    Recordset Operation

    Unfortunately ıt still doesn't work out. Booking Costs Period Dupl edited BC 222 22018 BC 76867 22018 AZ 34132 102018 AZ 41234 102018 MK 43214 32018 x MK 523 32018 MK 54134 32018 It gıves the error message: Run tıme error 3021: No current record
  16. B

    Recordset Operation

    Thanks for the post. Unfortunately it doesn't run through. Run-time error 3061: Too few parameters. Expected 1. Can you advise? Thank you.
  17. B

    Recordset Operation

    Hi all, I got following issue: There are two tables called Result and Duplicates. Now I want to mark all duplicated in the Result table. Here the content: RESULT TABLE (my goal): Booking Costs Period Dupl edited BC 2089 22018 BC 2089 22018 x AZ...
  18. B

    Run Access VBA code from .bat file

    Thank you all for the help. I've found a hot fix. The sub is copied to the new opened database, runs it there and deleted after the run. Now it works. Thank you. Kind regards, Ben
  19. B

    Run Access VBA code from .bat file

    Thank you Pat Hartman, the code I want to execute contains some more stuff not only changing links. I've checked the databases provided by thedbGuy, thanks for this. But the code is stored under the new opened database db1. I have the code in the original database and want to execute this...
  20. B

    Run Access VBA code from .bat file

    Thank you so far. Let me describe my issue. I got a database with a procedure I want to run in another database. It still doesn't work. I don't know the issue. I'm using Access 2013,maybe that's the issue??? Can I open a table in the new opened database, as a simple test? Thank you.
Top Bottom