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. flaubert

    Auto Number

    I assume you're using ADO with an access database... You need to access one of the dynamic properties of the field object in question. ADO objects have two kinds of properties - built-in and dynamic. Built-in properties are defined by ADO itself and are assigned to all objects. Dynamic...
  2. flaubert

    Windows file association?

    Hmm. This is interesting, because most of the time, icons are stored as resources rather than straight .ico files. I can't answer this, but hopefully I can point you in the right direction. First of all, you will need to poke around in the registry. Say for example you want to find the icon...
  3. flaubert

    aged?

    You could try processing the image yourself pixel by pixel. The colour of each pixel is given by an 8 digit hex number defining the brightness of each of the red, green and blue pixels on a scale of 0 to 255 (&H0 to &HFF). For white this would be &H00FFFFFF, ie. $H00<Red><Green><Blue> where...
  4. flaubert

    Working with OLE question

    First of all, I wouldn't use the OLE control if I didn't have to. Secondly ,when you say you want to write to it, do you mean programmatically, or do you want the user of your program to actually be able to type in it as if they were using Word itself? If the latter, then it might be worth you...
  5. flaubert

    Calling native COM from VB

    OK, this is all getting very confusing now! Sorry Jeff, you are of course right - if you have a type library then VB CAN access the object (although the TypeLib will need to contain the vtable for the object, not the DispIDs). If the TypeLib contains just the DispIDs (a dispinterface), then...
  6. flaubert

    Calling native COM from VB

    Whoa! Ok, forget definitions of COM and ActiveX. Jeff is correct - they are essentially the same thing. You say you need to access a &quot;native&quot; COM component. I'm not sure exactly what you mean by that, but here goes anyway: A COM component is defined as one that implements the...
  7. flaubert

    SQL-query in VB with Data1.recordset

    I assume that the error is occurring on the forllowing line: sql = &quot;SELECT Titel FROM Skiva WHERE Snr = '&quot; & Val(txtsnr.Text) & &quot;'&quot; Is Snr a text field or a numeric field? If it's numeric then you will get the above error because you have put quotes around the value you are...
  8. flaubert

    passing value

    What version of vb are you using? Assuming you are using vb5 or vb6 (I'm not sure about 4) then MichaelRed is wrong in saying that both forms must be open. If the value you have is in a text box on form1 (open) and you want to pass it to a text box on form2 (open or not), then the statement...
  9. flaubert

    Help with formula...

    Is the formula you've shown the one in the main report? If so, you need to initialise your variable - ie. you need to do something like shared numbervar prevmonth:= 0; rather than just shared numbervar prevmonth; If you don't initialise it like this in the main report, you will get a zero back.
  10. flaubert

    Crystal selection formula...Is the following possible???

    What's the error? It's not 'Type Mismatch' is it? selectionformula = &quot;renewal.counter = variables&quot; AND &quot;order.counter = variables&quot; will return this error in VB. From what I see, you need: selectionformula = &quot;renewal.counter = variables AND order.counter = variables&quot;
  11. flaubert

    Unique Parameter question

    It sounds like you need a UNION query for your report SELECT. ie. SELECT digits, street, apt [,1 ADDRTYPE] FROM address WHERE digits = digparam AND street = strparam AND apt = aptparam UNION SELECT wrongdigits, wrongstreet, wrongapt [,0 ADDRTYPE] FROM wrongaddress WHERE wrongdigits =...
  12. flaubert

    Help with formula...

    You're using a MonthName command that I don't have (V7?). However, given a month in the form of a string, the following: instr('FEBMARAPRMAYJUNJULAUGSEPOCTNOVDECJAN',left({?ReportDate},3))+2)/3 will return the NUMBER for the previous month. ie if {?ReportDate} is 'NOVEMBER', then it will...
  13. flaubert

    Proper use of Left(.) and right(.)

    Just out of interest, did you try the Replace solution? ie. instead of using: If InStr(1, cmbclub.Text, &quot;'&quot;) > 0 Then spot = InStr(1, cmbclub.Text, &quot;'&quot;) clublen = len(cmbclub.text) fmlatext = Left(cmbclub.Text, spot - 1) & &quot;' in {result.club} [1...
  14. flaubert

    Proper use of Left(.) and right(.)

    You could modify your code as follows fmlatext = &quot;{result.club} = '&quot; & Replace(cmbclub.Text,&quot;'&quot;,&quot;''&quot;) & &quot;'&quot; report1.SelectionFormula = fmlatext The Replace function is part of the VBA library if you are using VB6. The above will replace any instances of...
  15. flaubert

    Proper use of Left(.) and right(.)

    Hello, Firstly, I am not sure what you mean by the following: left('4',{result.club}) = 'Fred' and right('11',{result.club}) = 's Bass Club'&quot; The syntax of left is left(string,chars) which will return the left 'chars' characters of 'string'. Anyway, I think this is all beside the point...

Part and Inventory Search

Back
Top