CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeCharge.Discussion

 Help - dlookup still fails in event

Print topic Send  topic

Author Message
Frank Rocco
Posted: 06/23/2001, 6:28 AM

<SCRIPT Language="VBScript">
Sub assigned_to_onchange()
document.Bugs.bug_desc.value =
cstr(DLookUp("employees","employee_name","employee_id=1"))
End Sub
</SCRIPT>

Hello,
I tried javascript and am not trying vbscript.
if I replace the dlookup with a
document.Bugs.bug_desc.value = "test"
it works fine. dlookup generates Error: Type Mismatch 'DLookUp'

Can someone point me to what I am doing wrong?
Thanks
Frank

Dr. Scott R. Senay
Posted: 06/23/2001, 10:05 AM

Hi Frank!

It sounds to me like my original thought might be the case, dlookup won't
work inside a Javascript sript. You might want to use the dlookup OUTSIDE
the script, and then call the script passing the data into it...

Scott...


Frank Rocco <farocco@hotmail.com> wrote in message
news:9h25hk$pnu$1@news.codecharge.com...
> <SCRIPT Language="VBScript">
> Sub assigned_to_onchange()
> document.Bugs.bug_desc.value =
> cstr(DLookUp("employees","employee_name","employee_id=1"))
> End Sub
> </SCRIPT>
>
> Hello,
> I tried javascript and am not trying vbscript.
> if I replace the dlookup with a
> document.Bugs.bug_desc.value = "test"
> it works fine. dlookup generates Error: Type Mismatch 'DLookUp'
>
> Can someone point me to what I am doing wrong?
> Thanks
> Frank
>
>

Frank Rocco
Posted: 06/23/2001, 7:43 PM

Hi Scott,

It dows not seem to work inside of a vbscript either.
I'll see if I can figure out how to call it outside, I'm not sure.

Thanks
Frank


"Dr. Scott R. Senay" <drsenay@conceptech.com> wrote in message
news:9h2i8n$4e8$1@news.codecharge.com...
> Hi Frank!
>
> It sounds to me like my original thought might be the case, dlookup won't
> work inside a Javascript sript. You might want to use the dlookup OUTSIDE
> the script, and then call the script passing the data into it...
>
> Scott...
>
>
> Frank Rocco <farocco@hotmail.com> wrote in message
>news:9h25hk$pnu$1@news.codecharge.com...
> > <SCRIPT Language="VBScript">
> > Sub assigned_to_onchange()
> > document.Bugs.bug_desc.value =
> > cstr(DLookUp("employees","employee_name","employee_id=1"))
> > End Sub
> > </SCRIPT>
> >
> > Hello,
> > I tried javascript and am not trying vbscript.
> > if I replace the dlookup with a
> > document.Bugs.bug_desc.value = "test"
> > it works fine. dlookup generates Error: Type Mismatch 'DLookUp'
> >
> > Can someone point me to what I am doing wrong?
> > Thanks
> > Frank
> >
> >
>
>

Dr. Scott R. Senay
Posted: 06/24/2001, 10:18 AM

Hi Frank,

I'm betting, though I have not actually tried it, that dlookup won't work
inside VBscript for the same reason it won't work inside of JavaScript...
Both vbscript and javascript are interpreted fairly closed interpreted
systems, I can't see how they would have the smarts, or the capability to
yield to an external system.... AH HA! Talking it out this way it just
clicked, the one thing they BOTH have in common with each other, and DON'T
have in common with PHP or ASP is exactly that, they are external systems,
typically executed from the CLIENT side (a.k.a the browser) and are not
running on the server which means they have no access to the server or
server side functionality...

Now I have heard people talk about server side javascript but there are a
couple of problems with that, first it is even LESS efficient than ASP
(which is afterall a version of vbscript that runs on the server.) and two
I've never actually seen or heard of it done from a reputable source.
Ideally for a host of reasons you want your code running in the fastest,
most powerful system you can get it built in, this way when or if the system
grows you will not be stuck with a system you have to replace. Probably the
best known example of this is Fawcette's DevX.com service which started out
as ASP and VBScript, they grew quickly to the point where the system
collapsed from the demand placed on it, and they were forced to rip it all
out and re-build it pretty much from scratch in COM based visual basic.

I learned a great deal from FTP's early mistakes and avoid ASP for that
reason, but that is not to say you can't use it, you just need to take into
consideration the limitations of the envoironment you are building in... So
this is my long winded way of saying that code that works on server side
data MUST run on the server itself, aside from the performance issues, there
is the issue of security, I know of no web based system that allows client
side code to directly manipulate server data without a host of security.

Scott...


Frank Rocco <farocco@hotmail.com> wrote in message
news:9h3k44$uk4$1@news.codecharge.com...
> Hi Scott,
>
> It dows not seem to work inside of a vbscript either.
> I'll see if I can figure out how to call it outside, I'm not sure.
>
> Thanks
> Frank
>
>
> "Dr. Scott R. Senay" <drsenay@conceptech.com> wrote in message
>news:9h2i8n$4e8$1@news.codecharge.com...
> > Hi Frank!
> >
> > It sounds to me like my original thought might be the case, dlookup
won't
> > work inside a Javascript sript. You might want to use the dlookup
OUTSIDE
> > the script, and then call the script passing the data into it...
> >
> > Scott...
> >
> >
> > Frank Rocco <farocco@hotmail.com> wrote in message
> >news:9h25hk$pnu$1@news.codecharge.com...
> > > <SCRIPT Language="VBScript">
> > > Sub assigned_to_onchange()
> > > document.Bugs.bug_desc.value =
> > > cstr(DLookUp("employees","employee_name","employee_id=1"))
> > > End Sub
> > > </SCRIPT>
> > >
> > > Hello,
> > > I tried javascript and am not trying vbscript.
> > > if I replace the dlookup with a
> > > document.Bugs.bug_desc.value = "test"
> > > it works fine. dlookup generates Error: Type Mismatch 'DLookUp'
> > >
> > > Can someone point me to what I am doing wrong?
> > > Thanks
> > > Frank
> > >
> > >
> >
> >
>
>


   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.