Search results

  1. S

    You can't use FIND or REPLACE now

    I have had a lot of trouble with the replace function. every now and again it decides to stop working, rebooting the computer fixed this problem most of the time. I finaly tracked down the cause of this problem to using the defaut search option with the replace function. try something like...
  2. S

    Function for current drive & directory

    you can also use currentproject.path
  3. S

    VBA Coding

    Ok back to basic basics:D The error message your getting meens that either, OrigSelTop or SR.SelTop doesnt exist yet. (it will be SR) to find out which is a fault run the code when the code stops hover your mouse over the variables, or print them one at a time into the intemidiate window...
  4. S

    Set savename of report.snp

    I think what ur looking for is the .caption property of the report. I beleve this property is used to create the filename. give it a try :cool:ShadeZ:cool:
  5. S

    VBA Coding

    This sort of thing is above most access developers, but i can c where your going wrong in order to use a class u have to create an instance of that class (Using the NEW keyword) this can be done in 2 ways. 1, when the class var is declared, ie Private SR As NEW clsSetRow 2, or any where in...
  6. S

    Search between dates - Type mismatch??

    I have had a similar problem to this Query's cant take the value from the activex calendar i have 2 solutions 1) this might not work i didnt try this, change the reference to the atx_calendar to point at the calendar.value property not the calendar 2) this works, place a textbox with the...
  7. S

    Create an import specification on a variable text file???

    The answer is yes! VBA can do the job. Its a bit tricky so hope you can understand, Open a ado or dao recordset with all the data you need. With this data you can then create a text delimitated file in your format (i used the following format) {tablename}filed1,field2,field3,fieldN...
  8. S

    Autonumber Bug

    Im having a little trouble with the auto number, I have a table with the auto as the primary key, the problem is that the autonumber for new records is less than the max value of the autonumber field. eg max value in key field (2254) Value auto uses for a new record(2233) I didnt think this...
  9. S

    Problem adding new record with disabled navigation cmd buttons

    That seems over complicated to me try if me.recordset.eof then cmdlastrec.Enabled = False cmdnextrec.Enabled = False else cmdlastrec.Enabled = true cmdnextrec.Enabled = true end if if me.recordset.Bof then cmdprevrec.Enabled = False cmdfirstrec.Enabled = False else cmdprevrec.Enabled...
  10. S

    Notes Form

    Of corse its possible all you have to do is add a TextBox or something to ur main form. in the control scorce run a query to chk the notes eg) iif(nz(dlookup("notes","NoteTable","notetable.callid = " & Callid) ,"") <> "","!","") this should do the job :cool:ShadeZ:cool:
  11. S

    Between Start Time and End Time

    You can use the where Property on the report. if u use docmd.openacreport "MyReport",acpreview,,"Mydate >=#" & mystartDate & "# and Mydate <= #" & MyEnddate & "#" to open ur report. the other way is to get ur query to take the start and end date from your form. :cool:ShadeZ:cool:
  12. S

    round problem

    Look up INT and FIX in VBA Help :cool:ShadeZ:cool:
  13. S

    Can you pass parameters tween Access N Excel?

    Your answer is yes and no No, there is no real way to pass data to excel using the method u discribed. this method only opens up a copy of excel with the file selected. Yes. In order to edit excel spredsheet from within access u need to open excel using VBA and MSOffice Libraries. Its not that...
  14. S

    Division by zero

    try somthing like this =iif(nz(SomeField,0)=0,0,AField/SomeField) This will check if somefield is 0 or empty if so return a 0 else do the calculation. ie IIf((Nz([WtInLg])/Nz([No_Lg_Containers])*nz([LgfrWharf])=0,0, (Nz([WtInLg])/Nz([No_Lg_Containers])*Nz([LgfrWharf])))) Would be...
  15. S

    Do U use Spaces In Field Names????

    This Is very one sided does noone like Spaces, :cool:ShadeZ:cool:
  16. S

    Copy File Code Help?????

    Soz U should of said u were a vb nOOb ill make it simple for you Sub CopyFile(FileNameAndPath As String, FileNameAndDestination As String) Dim FSO As Object Set FSO = CreateObject("Scripting.FileSystemObject") FSO.CopyFile FileNameAndPath, FileNameAndDestination, True End Sub...
  17. S

    Do U use Spaces In Field Names????

    Ok quick poll for you Access Gurus DO!!! you use [S P A C E S]!!!!! in ur field names I personnaly dont use them they become anoying when doing SQL, Whats ur opinion????? :cool:ShadeZ:cool:
  18. S

    How to Select all Check Boxes with VBA

    ok, u have kicked ur self a bit in the foot on this one but u might be able to sort ur self out. First. Assuming "First Name" is a field name Y oh Y oh Y do people put spaces in field names, they are just an unnessasry nussance,:mad: :( :rolleyes: ok rant over try this or a vairiation on...
  19. S

    running plain SQL trough VBA?

    You dont have to use DAO for sql u can use ADO (My Favorite) :D to execute Sql use Currentproject.connection.execute sql[,Rows] ie, currentproject.connection.execute "delete * from MyTable" select queries can be done like this Set Rs = new adodb.recordset rs.open sql =...
  20. S

    capturing a count query in a variable?

    I have had Dcount error on me, without any error in the query the query ran fine from the query builder, but from dcount itwouldnt work. (Somthing to do with date values i was taking from another form):confused: But like i said earlier if it works and ur happy no problem. :cool:ShadeZ:cool:
Back
Top Bottom