Search results

  1. M

    Extract selection from Treeview or Listbox control

    Thank you David. This example is great. It describes exactly what I am doing. Thanks for that. The problem is behind the multi selection list box. I would like to avoid going through all values in list box. I thought that maybe there is a possibility to refer to the table or list or whatever of...
  2. M

    Extract selection from Treeview or Listbox control

    Hi guys, it is very useful to use the treeview or listbox control, let's say with multiply selection property. You can use the CTRL key to select multiply values in them. I have a problem to manage the selection. Do you know the way to refer to the selected values as they were some kind of list...
  3. M

    If Than elseif this is to difficult

    Thank You all, SQL is the best solution in my situation. It works very well now. It is, what I was looking for. Thanks again, Mathematician
  4. M

    If Than elseif this is to difficult

    So, I have table Cond and it has two columns: Condition, Result. And I have another table Final and here have Three columns: Name, Last Name, Age For example in thirst row in table Cond I have strings: Condition = "[Final].[Name]=Wayne and [Final].[Age]=123" Result="[Final].[Last Name]=Ryan"...
  5. M

    If Than elseif this is to difficult

    Thank You all, The two solutions above are grat. But i am trygin to implement it into the code and I cannot handle with it. Do you know how to make him to run the code like: sub test2() if eval([Tables]![Table Name]![Column Name]) then eval([Tables]![Table Name]![Column Name]) end sub...
  6. M

    If Than elseif this is to difficult

    Hi all, I would like to create the following code: ------------------------------------ sub test() condition= "4=4 and 5=5 and 6=6" result="msgbox("It is ok")" if condition then result end if end sub ------------------------------------ or sub test2() sentence="if 4=4 then msgbox("im...
  7. M

    docmd is very difficult

    Thank You very much DJkarl.
  8. M

    docmd is very difficult

    hi guys, do you know how to call the function "docmd" but in another DB. for example I am working on my.mdb and have the code inside: sub TransferSpreadsheet() set db=opendatabase("C:\another.mdb") with db DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel8, tbl.Name, DirectoryPathMain...
  9. M

    How to change table links in MDB file using VB?

    Hi all, i have few tables in *.mdb that are linked to *.xls files. I want to change their path link using VB in MS Access. Do you know how the change table properties to change their link to another path using VB code? (something like "Link Table Manager" but in VB code :) ) Thanks in advance...
  10. M

    Link csv file but with specific data type.

    Hi everyone, I have huge problem :( I have a *.csv file and a am linking it to my Access DB using this command: sub test() dim db as database set db=currentdb() with db DoCmd.TransferText acLinkDelim, , "Table_Name", "c:\my_file.csv", True end with end test You know that the TransferText...
  11. M

    Compact CurrentDB

    OK, Thanks any way :(
  12. M

    Link file to another DB

    Hi all, this code links specific file (my.csv) to currentdb. sub links_file() DoCmd.TransferText acLinkDelim, , "My_Name", "c:\my.csv", True end links_file Do you know how to link the same file but to another DB existing somewhere else? Thx in advance for any help. Mathematician
  13. M

    Compact CurrentDB

    Hi all, I would like to compact the same database I am working with, using VB. It shoul to work like this: sub compact() DBEngine.CompactDatabase "c:\my.mdb", "c:\my.mdb" end compact how to compel VB to compact the same data base where the code is. I don't want to compact to another location...
  14. M

    Too few parameters. Expected 1

    Try do like this: sql = "SELECT * FROM Failures WHERE rs![user ID] = Failures.[Sales Contact]" docmd.runsql sql
  15. M

    String Function

    Hi all, Do You know maybe if there is any function (lets name it: "desired_function") in VB making from any list of characters the one string varriable? I mean: sub dim I_am_text as String I_am_text=desired_function(Here is the " " very different text. With number 444 and stupid things...
  16. M

    How to call a procedure usign variable?

    Thank You, You are a genius:) The problem is solved. One more time thank You. Mathematician
  17. M

    How to call a procedure usign variable?

    Hi, I have procedure: sub test_thirst() msgbox("This is test") end sub and I would like to call this procedure using a variable as a name of the procedure above, I mean sth like this: sub run_variable() My_Variable="test_thirst" Call My_Variable ' Here my procedure test_thirst should to...
Back
Top Bottom