commenti Posted August 15, 2005 Share Posted August 15, 2005 Hello,I played around with code scriptkitty posted at this topic:http://www.autoitscript.com/forum/index.ph...572entry77572I could get successfull connections to different ODBC sources with this (for example MySQL). The script is nearly exactly what I need so I tried to modify it to fit my needs. Normaly I don´t use the beta so I am not used to the new COM Extensions.I have problems to understand this part: If .RecordCount Then $count=0 While Not .EOF $count=$count+1 tooltip("record search #" & $count & @crlf & $cmboVal,0,0) $cmboVal = $cmboVal & "" & .Fields("name").Value & "|" & .Fields("phone").Value & "|" & .Fields("address").Value & @cr .MoveNext WEndI need it to just "dump" all fields in the table of a database separated bei "|". How can I do it, if I don´t want to change everytime the .Fields("something") thing? Is there a way to find out how many .Fields exist and what there names are? Perhaps someone can push me in the right direction? I did not find something usefull about this "adodb" object.commenti Link to comment Share on other sites More sharing options...
DaleHohm Posted August 15, 2005 Share Posted August 15, 2005 (edited) The right direction for information here is the MSDN website. You'll find information specific to recordsets here Recordset ObjectWithout being familiar with COM and the Microsoft Object models you are going to have a lot of trouble with this unless you can just get someone to write what you need for you.That said, the code you include should get you pretty close. Some hits are that there is a Fields Collection that has a Count property. Also, the Field objects (included in the Fields collection) have a .Name property.Hope this helps,DaleEdit: fixed typo and removed copy of base post. Edited August 15, 2005 by DaleHohm Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble Link to comment Share on other sites More sharing options...
commenti Posted August 16, 2005 Author Share Posted August 16, 2005 Hi Dale, That said, the code you include should get you pretty close. Some hits are that there is a Fields Collection that has a Count property. Also, the Field objects (included in the Fields collection) have a .Name property.Hope this helps,Thank you, this was really helpfull seems you pushed me in the right direction. The link on MSDN for "Recordset Object" is really helpfull. Seems the Fields Collection properties are just what I need. I think I can figure out how to get this working now. Greetingscommenti Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now