Jump to content

Database


Recommended Posts

Is there a development for accessing databse with ODBC ? with taht's development it will be possible to use autolit in place of visual basic .

Second question : I use in visual basic the function open for reading BDE Borland files configuration IDAPI32.CFG

Function GetFileCont(sFile As String) As String

Dim FF As Integer

FF = FreeFile

GetFileCont = Space(FileLen(sFile))

Open sFile For Binary Access Read Lock Read As #FF

Get #FF, , GetFileCont

Close #FF

End Function

With that's function I can read this file. Is someone know how can i read this file with autolit (binary format) or eventually the name of a dll written in C which allow that's

Edited by LOULOU
Link to comment
Share on other sites

Database manipulation is not part of AutoIt and I do not expect it to be any time in the future. It is just too far from the main focus of AutoIt (automation of tasks on Windows computers).

As for your VB code, try

$GetFileCont = FileRead($sFile, FileGetSize($sFile))

David Nuttall
Nuttall Computer Consulting

An Aquarius born during the Age of Aquarius

AutoIt allows me to re-invent the wheel so much faster.

I'm off to write a wizard, a wonderful wizard of odd...

Link to comment
Share on other sites

  • 9 months later...

Database manipulation doesn't fit into the definition of automation of tasks? Isn't that somewhat of a narrow world view? How many Windows computers do you suppose there are in the world that are not part of a network containing a database server that is the central focus of their reason for existance? I seriously doubt they constitute a minority.

Please don't make the mistake of assuming that just because you don't have a use for it, no one else does either. Thinking outside the box is what makes a good idea into a great one.

I actually logged on here today looking for precisely this information. It's the one missing link for a number of automation tools I'm attempting to build, because they simply don't exist anywhere yet, for the doctor's office where I work, to help my fellow employees manage the headaches caused by all the various software they have to deal with. Appointments, patient charts, billing, inbound faxes and lab reports -- that's five separate software packages right there, and just the beginning. Yet large parts of the information in each of them overlap -- patient demographics, for instance. Every day they enter the same information in multiple places, and they have to manually check in several places for their various tasks, and remember to update information in multiple places when it changes.

AutoIt has allowed me to begin tying some of the functionality together for them, eliminating human error as well as streamlining many of their processes. I have a lot more ideas yet to pursue. But for 85% of them I need to access database information in order to do what needs to be accomplished.

Jumping in with both feet...

LadyLong

.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo"I came to realize that life lived to help others is the only one that matters. This is my highest and best use as a human." -- Ben Stein
Link to comment
Share on other sites

Please don't make the mistake of assuming that just because you don't have a use for it, no one else does either. Thinking outside the box is what makes a good idea into a great one.

You too categorical. I'ts impossible to add features that's fits one-two people needs. In this case Autoit quickly become some sort of bloatware. But we will have a chance to work with databases - look in developers forum for this thread.

Link to comment
Share on other sites

You too categorical. I'ts impossible to add features that's fits one-two people needs. In this case Autoit quickly become some sort of bloatware. <snip>

<{POST_SNAPBACK}>

You guys crack me up. :) Not in a mean way, don't read this wrong, 'cause I'm smiling as I type. :huh2:

So am I just old, or what? Where is this part of the world where such an insignificant percentage of the population is database-dependent??? Or are you all just working on solutions for personal systems? Maybe I'm looking at this from a professional point of view instead of that of a hobbyist, but it sure seems to me that AutoIt is worthy of being ranked as a professional tool.

I've worked in the computer industry since the year the IBM PC was introduced (Yeah, yeah, I can guess how many of you weren't born yet!) and the last time I remember dealing with an issue that *didn't* in some way involve a database was in 1993! Do you really mean to tell me there are THAT many automation issues out there that have nothing to do with nor any need to access information stored in a database? To the extent that some of you still think it would be excess baggage? Ohmygoodness!

I remember when a lot of programmers thought nobody needed anything more than Edlin to write code. There used to be a mail sig that said "Real programmers use COPY CON > PROGRAM.COM." When GUI came along most of us rolled our eyes and turned back to our command lines. Colors and pretty pictures and clicky icons were for children's games. Talk about bloat! :lmao:

Even if you're using AutoIt for its original purpose, configuring systems -- I can imagine a database solution for that, too, with different configurations defined and scripts dynamically assembled to match the individual system. Okay, so I worked too long for a VAR systems reseller, where every system going out the door might have a different configuration based on the customer's order. The same hardware database that my "configurator" logic used (the quoting engine that actually kept clueless salesmen from selling systems with two video cards and an RLL drive controller with an MFM drive -- TOLD you I'm old!) could have fed the logic for a scripted installation process based on the system configuration. In fact I built it using a web scripting language that AutoIt reminds me of a lot, and we stretched it beyond anything its author had ever dreamed it would be doing. And he loved it. :)

Ah, well. It looks like you're headed that way (database interactivity) anyway, and I'm not an IT professional any more, I'm a nursing student who gets drafted to help doctors with their computer problems from time to time - so it's no big deal to me, just something to smile my knowing old person smile at. :whistle: I don't have a team of C+ programmers at my disposal any more, but I'm finding ways to do the little things I need to do, even if they're not as elegant as I'd like. I'm the only one who knows they're not elegant, so it really doesn't matter.

AutoIt is a beautiful thing. I'm happy. The world is good. :)

LadyLong o:)

.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo"I came to realize that life lived to help others is the only one that matters. This is my highest and best use as a human." -- Ben Stein
Link to comment
Share on other sites

I managage a database using autoit3 just open windows,click on buttons and

send shortcut keys.

the beauty of autoit is in the way it can automate your typing :lmao:

of course there is nothing better than running ODBC but if you really need it

use perl or GUILECT which can be controlled by autoit.

p.s.

I love GAWK but I know it cant do everything and well, I still love it. Just know

that you will have to learn a few languages to really do everything.

Link to comment
Share on other sites

LadyLong, I'm will not start dispute with you. If nothing else my english not even good, so I just have no chance. I'm even will not boast of my stage and when I born and when I start working with something - this is no matter. If this is mutually misunderstanding - sorry.

I'm even not try to said that this feature is rarely used, it was asking many times at the board. But please don't make the mistake of assuming that if just because you have a use for something, that should be usefull for all. That all what I (was) want to say.

AutoIt is a beautiful thing. I'm also happy. The world is good. :lmao:

Link to comment
Share on other sites

LadyLong, I'm will not start dispute with you. If nothing else my english not even good <snip>

<{POST_SNAPBACK}>

Hey, Lazycat! :lmao:

No disputes wanted. And I wasn't boasting, not a bit -- just trying to offer others a way to see the question from my perspective. Text on a screen doesn't do much to tell you where a person is coming from, it usually helps me to know a little of the background of the person I'm talking with, so I just figure it is helpful the other direction too. Mostly I wanted you to know I wasn't just assuming something is useful because it would be for me, but that I've been around a little bit and had to help people figure out solutions that didn't exist for a lot of different problems, so I wasn't just basing my comments on what *I* need.

I've had my say on that, so I will shut up now, but I *DO* want to say this to you:

For goodness' sake, don't apologize for your English, at least not to me. I don't know what your native language is, but there's a really good chance I couldn't possibly make myself understood in it, much less in writing. So you're 'way ahead of me, and probably most of the other Americans here, in terms of linguistic abilities. If anyone's got anything to apologize about, it's sure not you -- it's the ones who can't even spell or properly punctuate in their own native language, let alone another one! (Ironically enough, they're usually the first ones to act superior when a non-native English speaker makes a mistake... go figure! o:))

With respect,

LadyLong

.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo"I came to realize that life lived to help others is the only one that matters. This is my highest and best use as a human." -- Ben Stein
Link to comment
Share on other sites

I managage a database using autoit3 just open windows,click on buttons and send shortcut keys.

<snip>

Just know that you will have to learn a few languages to really do everything.

<{POST_SNAPBACK}>

Hi Normeus,

Opening windows and clicking won't work with a SQL database, unless I install SQL tools on every workstation, and for the offices that ask me for solutions, that's not a possibility. :) I've done a few things for some of them in Access, but oh, man how I hate Access!!! :lmao:

As for learning more languages -- nopenopenope, I'm all done with that. I've learned a few in my day, but they just keep becoming defunct so I have to start over again. (Hey, I could once even sight-read FORTRAN off punch cards... o:) ).

This stuff is JUST a hobby from now on. I'm saving my remaining brain cells for anatomy and physiology, organic chemistry, pathology, abnormal psychology.... :)

LadyLong

.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo.oOo"I came to realize that life lived to help others is the only one that matters. This is my highest and best use as a human." -- Ben Stein
Link to comment
Share on other sites

  • 1 month later...

In case there is a needs-assesment going on right now, I just wanted to say that I, too, have need to connect to an ODBC database. I use AutoIt to control the application of updates to our clients. Sometimes that involves adding rows to a database table. Right now, we're (mis)using a tool we developed to alter database structure to do that job, but it's not pretty.

I also want to commend everyone involved with this project. When I first found v2.0, I thought "Yeah, I might have a use for this." Then v3.0 came out, and I was amazed. Then, you added a GUI, and I realized that AutoIt had changed from a sidekick that I could use for simple tasks in place of "real" programming tools, to a real programming tool itself, but one that is (almost) exactly what I'm looking for.

Kudos, bigtime.

Link to comment
Share on other sites

In case there is a needs-assesment going on right now, I just wanted to say that I, too, have need to connect to an ODBC database. I use AutoIt to control the application of updates to our clients. Sometimes that involves adding rows to a database table. Right now, we're (mis)using a tool we developed to alter database structure to do that job, but it's not pretty.

You is at the time. The COM is COMing :) Download latest beta with COM support and try to play with it... it's awesome.

http://www.autoitscript.com/forum/index.php?showtopic=9202

Link to comment
Share on other sites

Yeah, from AutoIt it's no problem to access a database with ODBC !

Last autumn I had the same challenge. Then I searched this forum by "ODBC" and found useful info.

At http://www.analogx.com/ you will find AnalogX SQLCMD which allows you to quickly and easily run SQL queries against ODBC

data sources. Basically, it's a simple portable way to execute SQL commands from batch files, etc.

AnalogX SQLCMD version 1.00 (Release)

The latest version can always be found at http://www.analogx.com/.

Go to >Download, >System Download and then >Commandline Utilities

Usage: SQLCMD [options]

Options: /USER [name] Username to login as

/PASS [password] Password for username

/DB [database] Name of ODBC connection to use

/LOG [filename] Log results to file

/APPEND Append results to file

/SILENT Do not decode results

/COMMAND [cmd] SQL command to execute

Download AnalogX SQLCMD from analogx.com , and put the sqlcmd.exe in the same folder as the script. That's it.

This is the last part of my script where I use sqlcmd.exe as ODBC for getting access to my local database;

..

Dim $sql ="INSERT INTO feil (Navn) VALUES('"&$date&"')"

Run ('sqlcmd.exe /db "Feilreg" /user "root" /append /command "' & $sql & '"','',@SW_MINIMIZE)

Exit

Good luck!

best regards

Lars Roan, Norway

Lars RoanBergen, Norway

Link to comment
Share on other sites

I believe AutoIT can do this... I may be mistaken.

http://www.autoitscript.com/forum/index.php?showtopic=9296

"I thoroughly disapprove of duels. If a man should challenge me, I would take him kindly and forgivingly by the hand and lead him to a quiet place and kill him." - Mark TwainPatient: "It hurts when I do $var_"Doctor: "Don't do $var_" - Lar.
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...