Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / December 2004

Tip: Looking for answers? Try searching our database.

JavaScript to C# ?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mattia Saccotelli - 02 Dec 2004 11:23 GMT
How to convert this JS:

function btnShowOrderDetails::OnClick(eventObj)
{
    // Show the order details for the order that this button corresponds to.
    if (eventObj.Source.baseName == "Orders")
        ShowOrderDetails(eventObj.Source.getAttribute("OrderID"));
}

to C# code?

May be to this?

public void btnTest_OnClick(DocActionEvent e) {
    e.Source.attributes.getNamedItem("OrderID") [...]
}

??
Mattia Saccotelli - 02 Dec 2004 13:34 GMT
this works (with a dynamic button in a repeating table with controls):

thisXDocument.UI.Alert(
    "" + e.Source.attributes.length + " " +
    e.Source.xml + " " +
    e.Source.attributes[0].text + " " +
    e.Source.attributes.getNamedItem("ID").text
    );

> How to convert this JS:
>
[quoted text clipped - 15 lines]
>
> ??
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.