Search results

  1. L'apprentis

    Type Mismatch in function?

    Cheers Selenau, it seems to be working, Here is a sample with the code, I think I could still improve it by making the function work by using values taken from tables directly but I am not sure how to do it.
  2. L'apprentis

    Type Mismatch in function?

    Yes, I see what you are saying and I think that you are right. How could I apply the Select case structure to that situation? What do you think about using a table as I have suggested in my last post? Do you think it's possible?
  3. L'apprentis

    Type Mismatch in function?

    Cheers Bat 17. Openind the DAO Library allowed my code to work. Thanks for your reply as well Selenau 837. Now that I have been able to implement my code, I am facing a new problem: 1 of the constant used for the calculation (CurYNickel) is deducted from an other constant CurXnickel as...
  4. L'apprentis

    Type Mismatch in function?

    To Selenau837: Thanks for your replies, This is how i call the function for the moment, using a command button, Private Sub CmdCalculate_Click() On Error GoTo Err_CmdCalculate_Click Weight = TxtWeight TxtCastingPrice = FctCastPrice(Weight) Exit_CmdCalculate_Click: Exit Sub...
  5. L'apprentis

    Type Mismatch in function?

    I have change "3" to 3...It still not working,
  6. L'apprentis

    Type Mismatch in function?

    Yes, sorry...I have changed it and I still get mismatch error Is it not possible to multiply a currency by a "constant" Public Function FctCastPrice(Weight As Double) As Currency 'Code to get the Price of casting just by knowing its weight and material [low carbon (LC) or stainless Steel (SS)]...
  7. L'apprentis

    Type Mismatch in function?

    Hello, I am writting my first function and I am facing a mismatch error, I don't know why. The function is quite long but I have reduced it to the following code and I am still getting the mismatch error? Is there any error in the following code? I have also check the format of tablconst where...
  8. L'apprentis

    Close disabled on open

    Thank you again Ghudson, I am not sure I understand everything but it works. It didn't expect it to be so tricky, i am going to have a look into it though..
  9. L'apprentis

    Close disabled on open

    I am trying to get one of my form impossible to be closed until a event occur. I have tryed to write the following event on the open event of the form and it doesn't work. Does anybody know why? Forms!FrmNewDrawingFile.CloseButton = False
  10. L'apprentis

    Combo Box Format

    Ghudson, if one day you need to deal with what we discussed you might want to have a look at the following thread where you'll find a great sample data base under Sort.zip. http://www.access-programmers.co.uk/forums/showthread.php?t=83419 ;)
  11. L'apprentis

    Hyperlink?

    Thanks again for your help, You are correct : Hyperlink = DisplayText#Address#
  12. L'apprentis

    Allow the "*" use in cbo box with number format

    Thanks for your reply, I understand what you are saying, this is not an ideal situation as I wanted the user to be able to jump between specific data and "all" data viewing. I will change the criteria as you suggested, though.
  13. L'apprentis

    Allow the "*" use in cbo box with number format

    Don't know if you noticed but I am kinda of struggling with my Cboboxex and my fields format...I am getting there but I find it a bit tricky just for something that seems so trivial.:rolleyes: :rolleyes: I have the following cbo boxe bound to a number: SELECT DISTINCT TblDrawing.SheetNo FROM...
  14. L'apprentis

    Combo Box Format

    I see...Thanks anyway for your help. It has been really helpfull.
  15. L'apprentis

    Hyperlink?

    I have created a very simple code to fill automaticly an hyperlink field when a text box is updated on a form: Me.txtHyperlink = "F:\Data\CPP\CPP PDF\" & [TxtPipeSize] & "\" & [DrawingFile] & "\" & [PartNumber] & ".sht" & [TxtSheetNo] & ".Rev" & [TxtRevNo] & ".pdf" TxtHyperlink is bound to the...
  16. L'apprentis

    Combo Box Format

    I see what you mean, this is quite an interesting and simple method to get round it indeed: SELECT DISTINCT TblCasing.CasingOD, Format([CasingOD],"#,##0.000") AS OD FROM TblCasing WHERE (((Format([CasingOD],"#,##0.000"))<>0)) ORDER BY TblCasing.CasingOD; How would you do then if you were...
  17. L'apprentis

    Combo Box Format

    I really don't want to be a pain but how do you add an hidden field to a query? I am really sorry for being annoying.
  18. L'apprentis

    Combo Box Format

    I managed to make it work, i forgot to use the Format again in the Order By Cllause: SELECT DISTINCT Format(CasingOD,"#,##0.000") AS OD FROM TblCasing WHERE (((TblCasing.CasingOD)<>0)) ORDER BY Format(CasingOD,"#,##0.000"); Now I am facing a different kind of problem, the record are put in...
  19. L'apprentis

    Combo Box Format

    I have changed the row source and it seems to work fine, but now I get a problem when i am adding the ORDER BY clause: SELECT DISTINCT Format(CasingOD,"#,##0.000") AS OD FROM TblCasing WHERE CasingOD<>0 ORDER BY OD; I get the following error message: ORDER BY clause (OD) conflicts with DISTINCT.
  20. L'apprentis

    Please help beginner with football d/b design

    Well, It's going to be a bit more difficult than you expect. I advise you to do a bit of reading and use the search option of this forum; it did help me quite a lot. For the combobox you should look for 'cascading comboboxe', you have a very cool tutorial in the sample database section. For...
Back
Top Bottom