Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Re: call javascript function with databinder-value?

Reply
Thread Tools

Re: call javascript function with databinder-value?

 
 
Raterus
Guest
Posts: n/a
 
      05-24-2004
What exact problem do you have, you definitely look to be on the right track though. If I had to guess though, the compiler is getting confused with single-quotes within single-quotes.

--Michael

"p dietz" <(E-Mail Removed)> wrote in message news:(E-Mail Removed)...
> Hello NG,
> I want to create a asp.net-Hyperlink-Button by using Databinder-methods within a javascript-call, but i'm not able to find the right way.
> I believed something like this:
> <asp:hyperlink id=Hyperlink1 runat="server" Font-Names="Tahoma" Font-Size="XX-Small" NavigateUrl="javascript:OpenCal('<%# DataBinder.Eval(Container, 'DataItem.GEBURTSDATUM', '{0:d}') %>','txEditGebDat')">Kalender</asp:hyperlink>
>
> OpenCal is the javascript-function which should open a calender with the given date (by databinder).
> In fact, in the generated html-page it should be
> <a href="javascript:OpenCal('24.05.2003','txtEditGebD at')>
>
> What must i do to make it run?
> Thanks
> Peter
>

 
Reply With Quote
 
 
 
 
=?Utf-8?B?cCBkaWV0eg==?=
Guest
Posts: n/a
 
      05-24-2004
Hello
I've tried a lots of possibility - nothing works. One time, the page can not be loaded because of compiler error in this line, or other times it loads, but does not work ( the link gets something like javascriptpenCal("<%# databinder..."))
I've also tried to make a "normal" HTML-Link by <a href="javascript.openCal(' databinder-expression '), but this has the same problem. I also believe that the key to work is the correct use of ' and " - but how is the correct use

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to call function whose function call with arguments is in astring Options grbgooglefan C Programming 4 01-30-2008 05:12 PM
How to call function whose function call with arguments is in astring grbgooglefan C++ 2 01-30-2008 07:18 AM
How to call function whose function call with arguments is in astring Options grbgooglefan C Programming 0 01-30-2008 04:19 AM
defined? for recursive function call v/s defined? for function call stack Alok Ruby 3 04-13-2006 11:53 AM
write a function such that when ever i call this function in some other function .it should give me tha data type and value of calling function parameter komal C++ 6 01-25-2005 11:13 AM



Advertisments