Professional OPC
Development Tools

logos

Online Forums

Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.

Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.

Do not use the Contact page for technical issues.

ASP.NET - WebForm application - how to begin

More
08 Jun 2016 12:14 #4114 by support
You should have QuickOPC entries in your Start menu. Under Windows 7, they are hierarchically organized under All Programs -> OPC Labs -> QuickOPC 5.3x. Under Windows 8 and 10, it may be organized differently (flat), but they are still there.

Among the entries, there is Examples (.NET Source Code) -> Visual C# Examples. Clicking on it will open a solution in Visual Studio with most our examples. In VS then, in its Solution Explorer, there is a folder named Web; under that folder, there is the WebApplication1 project.

The solution with all the examples can alternatively also be opened directly from the disk. Its usual location is C:\Program Files (x86)\OPC Labs\QuickOPC 5.3\ExamplesNet\CSharp\VS2012\QuickOpcCSharpExamples.sln.

I hope this helps

Please Log in or Create an account to join the conversation.

More
08 Jun 2016 07:27 #4113 by forum-dv
code you posted helped a lot.

However I couldn't find WebApplication1 project.
Maybe I am missing something?

Thanks

Please Log in or Create an account to join the conversation.

More
07 Jun 2016 11:36 - 07 Jun 2016 11:36 #4087 by support
You can use QuickOPC to integrate OPC client functionality within an ASP.NET (Web Forms) application, but the Live Binding support (and therefore, the toolbox) is not available in Web Forms - only in Windows Forms (desktop).

Eseentially, you need to instatiate one of EasyXXClient objects (e.g. EasyDAClient for OPC Data Access, or EasyUAClient for OPC Unified Architecture), and then call methods on it to achieve what you want.

Some very basic wxamples for this come with the product: Open the C# or VB.NET Examples solution, and it has a solution subfolder named Web with several projects. BTW, the list of examples is here: www.opclabs.com/files/documents/QuickOpc/Latest/Examples-QuickOPC.pdf on the Documentation page (www.opclabs.com/resources/documentation).

The shortest of all examples is the WebApplication1 project. It contains just one text box on the page, and its code-behind goes like this:
using OpcLabs.EasyOpc.DataAccess;
using System;
 
namespace WebApplication1
{
    public partial class _Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            var client = new EasyDAClient();
            object value = client.ReadItemValue("", "OPCLabs.KitServer.2", "Demo.Single");
            TextBox1.Text = (value == null) ? "" : value.ToString();
        }
    }
}

The code reads an OPC value and displays it in the text box of the ASP.NET Web Form.

I hope this helps.

Best regards
Last edit: 07 Jun 2016 11:36 by support.
The following user(s) said Thank You: forum-dv

Please Log in or Create an account to join the conversation.

More
07 Jun 2016 09:55 #4086 by forum-dv
Hello!

I have QuickOPC.NET 5.23 and I want create an ASP.NET WebForm Application.

I cannot find any toolbox items or example to start with.

Can anyone help?

Regards

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.088 seconds