<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ASP.NET (VB.NET) - cwui.ocx &amp;quot;errors loading control&amp;quot; error in Measurement Studio for .NET Languages</title>
    <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91698#M143</link>
    <description>I'm not sure what you're asking since you said you want to set the value via code but want to avoid scripting.  If you're not going to use scripting, what code are you referring to?  Do you mean set the value via code on the server?  If so, this will be a little tricky since the ActiveX controls are activated on the client.  You'll have to do something like what I mentioned in #2 in my last post in one of our &lt;A href="http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&amp;amp;RPAGEID=135&amp;amp;HOID=50650000000800000096760000&amp;amp;UCATEGORY_0=_47_%24_7_&amp;amp;UCATEGORY_S=0"&gt;previous threads&lt;/A&gt;.&lt;BR /&gt;&lt;BR /&gt;Just out of curiosity, why the aversion to scripting?  It's probably the easiest solution to what you wer&lt;BR /&gt;e asking and scripting should be supported on any browser that supports hosting ActiveX controls.&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
    <pubDate>Mon, 14 Jul 2003 02:17:55 GMT</pubDate>
    <dc:creator>Elton Wells</dc:creator>
    <dc:date>2003-07-14T02:17:55Z</dc:date>
    <item>
      <title>ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91685#M130</link>
      <description>I'm trying to use the cwKnob control (cwui.ocx) in a webform (ASP.NET / VB.NET). I place it on a webform and import a style and it looks great. I save it, then close the solution and reopen it and when I goto the page I get this error: "Errors loading control. The default settings for the control will be used."&lt;BR /&gt;&lt;BR /&gt;I've tried replacing the control several times. Any ideas? Has anyone got this control working on a webform? If so, I'd be EXTREMELY interested. &lt;BR /&gt;</description>
      <pubDate>Thu, 03 Jul 2003 19:46:10 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91685#M130</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-03T19:46:10Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91686#M131</link>
      <description>Interestingly enough when I create a new Windows Application (VB.NET) the knob control works fine.&lt;BR /&gt;&lt;BR /&gt;I've uninstalled/reinstalled Meas. Studio 6 a few times and still have this crazy problem.&lt;BR /&gt;&lt;BR /&gt;Please help! &lt;BR /&gt;</description>
      <pubDate>Thu, 03 Jul 2003 21:29:07 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91686#M131</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-03T21:29:07Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91687#M132</link>
      <description>First, a disclaimer: the Measurement Studio ActiveX controls are not officially supported in ASP.NET, so there are no guarantees regarding how well the controls will work in ASP.NET applications.&lt;BR /&gt;&lt;BR /&gt;Having said that ... the differences that you're seeing with the knob between ASP.NET and Windows Forms have more to do with the nature of each of those respective environments and less to do with the behavior of the knob.  In Windows Forms, a .NET wrapper class is generated for the ActiveX object and settings are persisted as generated code using that auto-generated interface.  In ASP.NET, the settings of the knob are persisted as nested param tags of the HTML object tag.  The error that you're seeing is from loading the persisted settings.&lt;BR /&gt;&lt;BR /&gt;One way to work aroun&lt;BR /&gt;d this would be to create a user control in VB6 that hosted the knob control with your custom settings.  Your settings would be persisted as they would be in any other VB application, which works very well.  Then you could use your user control in a web page and since you handled all of your settings when creating the user control, the only values that you would need to customize in your object tag are the width and the height.&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
      <pubDate>Fri, 04 Jul 2003 23:28:00 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91687#M132</guid>
      <dc:creator>Elton Wells</dc:creator>
      <dc:date>2003-07-04T23:28:00Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91688#M133</link>
      <description>Thanks. I will try this. Do you know if NI is planning to come out with real, .NET managed, server side ASP.NET controls? If so when? &lt;BR /&gt;</description>
      <pubDate>Tue, 08 Jul 2003 13:01:37 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91688#M133</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-08T13:01:37Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91689#M134</link>
      <description>This is certainly an area that we are looking into.  As with any new product or technology, we are always looking for feedback.  If you're interested in Measurement Studio ASP controls, please feel free to contact me directly at shelley.erickson@ni.com with product suggestions and application examples.&lt;BR /&gt;- Shelley &lt;BR /&gt;</description>
      <pubDate>Tue, 08 Jul 2003 16:31:26 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91689#M134</guid>
      <dc:creator>Shelley</dc:creator>
      <dc:date>2003-07-08T16:31:26Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91690#M135</link>
      <description>Elton, so what you are saying is to create a user control in VB.NET with the NI knob inside of it, then use this user control (now "managed") in ASP.NET? &lt;BR /&gt;</description>
      <pubDate>Tue, 08 Jul 2003 20:18:14 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91690#M135</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-08T20:18:14Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91691#M136</link>
      <description>You could try that, but what I was actually suggesting was to create a user control in VB6 that hosted the Measurement Studio knob control, then use this user control in your web page like any other ActiveX control.  I think this is the easiest way to do this.  &lt;BR /&gt;&lt;BR /&gt;If you created an ASP.NET user control in VB.NET, you would still have the same persistence issues that you had when trying to use the control in an ASP.NET page.  If you created a Windows Forms user control, you would introduce a dependency to the .NET Framework on the client, which is probably undesired.&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
      <pubDate>Tue, 08 Jul 2003 20:57:35 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91691#M136</guid>
      <dc:creator>Elton Wells</dc:creator>
      <dc:date>2003-07-08T20:57:35Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91692#M137</link>
      <description>First off, thanks for all your help so far. You are an invaluable resource!&lt;BR /&gt;&lt;BR /&gt;Based on your suggestion I created a new VB6 "ActiveX Control" project. I put the CWKnob control on it along with a label. Here is my simple code:&lt;BR /&gt;&lt;BR /&gt;Public Sub SetValue(Value As Integer)&lt;BR /&gt;    CwKnob.Value = Value&lt;BR /&gt;    lblValue.Caption = CwKnob.Value&lt;BR /&gt;End Sub&lt;BR /&gt;Public Function GetValue() As Integer&lt;BR /&gt;    GetValue = CwKnob.Value&lt;BR /&gt;End Function&lt;BR /&gt;&lt;BR /&gt;I created MyKnob.ocx and tested it in another VB6 standard application - worked fine! I could set the value, read it, etc... &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I went to a new ASP.NET webform and added the reference to the ocx. I "drew" the gauge on the webform - no problem.  Questions:&lt;BR /&gt;&lt;BR /&gt;1. How can I set the value of the Activ&lt;BR /&gt;eX control (either by using my SetValue function, or by another means)? (I set the ID/Name of the new control, but I can't simply say MyCtrl.SetValue. I assume I'll have to use a PARAM manipulation, but I don't any useful PARAM settings.)&lt;BR /&gt;&lt;BR /&gt;2. When I run the form I always get this msg now: "This page provides potentially unsafe information to an ActiveX control. Your current security settings prohibit running controls in this manner. As a result, this page may not display correctly." It seems like it's an IE problem, but I hope my users won't have to make changes to their IE settings just to view this webpage. Any ideas?&lt;BR /&gt;&lt;BR /&gt;I've attached the OCX file for your reference.&lt;BR /&gt;&lt;BR /&gt;Thanks for your help! &lt;BR /&gt;</description>
      <pubDate>Wed, 09 Jul 2003 12:36:19 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91692#M137</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-09T12:36:19Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91693#M138</link>
      <description>1.) Instead of defining GetValue and SetValue methods on the control, define a Value property, like this:&lt;BR /&gt;&lt;BR /&gt;Public Property Get Value() As Integer&lt;BR /&gt;    GetValue = CwKnob.Value&lt;BR /&gt;End Property&lt;BR /&gt;&lt;BR /&gt;Public Property Let Value(val As Integer)&lt;BR /&gt;    CwKnob.Value = Value&lt;BR /&gt;    lblValue.Caption = CwKnob.Value&lt;BR /&gt;End Property&lt;BR /&gt;&lt;BR /&gt;Once you have a property, you should be able to set it via param tags.  Alternatively, you could call the method in the page's load event.&lt;BR /&gt;&lt;BR /&gt;2.) One thing you could do is code sign your control.  See &lt;A href="http://msdn.microsoft.com/library/default.asp?url=/workshop/security/authcode/intro_authenticode.asp"&gt;Introduction to Code Signing&lt;/A&gt; for more information.  Once your control is code signed, users would get a p&lt;BR /&gt;rompt the first time they access the page.  If they specify that they trust the publisher (you), the control would be installed and the control should work the next time they access the page.&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
      <pubDate>Wed, 09 Jul 2003 18:15:37 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91693#M138</guid>
      <dc:creator>Elton Wells</dc:creator>
      <dc:date>2003-07-09T18:15:37Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91694#M139</link>
      <description>Per your suggestion I made them properties. In my HTML I still don't see those values as available PARAM's. Here's the HTML in my aspx webform...&lt;BR /&gt;&lt;BR /&gt;&lt;OBJECT id="ucMyKnob" classid="clsid:7CF..." name="ucMyKnob" viewastext=""&gt;&lt;BR /&gt;	&lt;PARAM name="_ExtentX" value="3228" /&gt;&lt;BR /&gt;	&lt;PARAM name="_ExtentY" value="2937" /&gt;&lt;BR /&gt;&lt;/OBJECT&gt;&lt;BR /&gt;&lt;BR /&gt;Do you know how I can expose, view and change the PARAM values?&lt;BR /&gt;&lt;BR /&gt;Thanks again. &lt;BR /&gt;</description>
      <pubDate>Wed, 09 Jul 2003 20:30:27 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91694#M139</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-09T20:30:27Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91695#M140</link>
      <description>How are you determining what are available values for params?  If you defined a Value property, you should be able to do something like this:&lt;BR /&gt;&lt;BR /&gt;&lt;OBJECT id="ucMyKnob" name="ucMyKnob" classid="clsid:7CF..."&gt;&lt;BR /&gt;    &lt;PARAM name="Value" value="5" /&gt;&lt;BR /&gt;&lt;/OBJECT&gt;&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
      <pubDate>Wed, 09 Jul 2003 21:32:35 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91695#M140</guid>
      <dc:creator>Elton Wells</dc:creator>
      <dc:date>2003-07-09T21:32:35Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91696#M141</link>
      <description>This is how I set the value: In VB.NET, for example, I created a winform with the simple 'MyKnob' user control and a button. The button has this code:&lt;BR /&gt;&lt;BR /&gt;Private Sub Button1_Click(...) Handles Button1.Click&lt;BR /&gt;   MsgBox(ucMyControl.get_Value)&lt;BR /&gt;   ucMyControl.set_Value(20)&lt;BR /&gt;End Sub&lt;BR /&gt;&lt;BR /&gt;This works fine.&lt;BR /&gt;&lt;BR /&gt;In my webform I place the control, but I don't see any PARAMs other than "_ExtentY" and "_ExtentX", so I MANUALLY tried to add both "Value" and (on another attempt) "set_Value" with values of "60". For example:&lt;BR /&gt;&lt;BR /&gt;&lt;OBJECT id="MyKnob" classid="clsid:7C..." name="MyKnob" viewastext=""&gt;&lt;BR /&gt;	&lt;PARAM name="_ExtentX" value="3228" /&gt;&lt;BR /&gt;	&lt;PARAM name="_ExtentY" value="2937" /&gt;&lt;BR /&gt;	&lt;PARAM name="set_Value" value="&amp;lt;br" /&gt;"60"&amp;gt;&lt;BR /&gt;&lt;/OBJECT&gt;&lt;BR /&gt;&lt;BR /&gt;When I run the webform I see the knob fine, but the value is still set to the default.&lt;BR /&gt;&lt;BR /&gt;I feel like I'm getting closer. Thanks for your help! &lt;BR /&gt;</description>
      <pubDate>Thu, 10 Jul 2003 11:39:03 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91696#M141</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-10T11:39:03Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91697#M142</link>
      <description>Elton, I actually made some GREAT headway. Thanks.&lt;BR /&gt;&lt;BR /&gt;One of the KEYS to using these controls in ASP.NET is to add the CWUIControlsLib REFERENCE to my project. (Then I can access the custom property pages of the control, etc...)&lt;BR /&gt;&lt;BR /&gt;Now, if I want to dynamically set the PARAM "Value_21" (actual pointer value) via CODE how do I do this? (I seem to remember using InnerHtml, but don't recall exactly.) I'd like to avoid scripting if at all possible!&lt;BR /&gt;&lt;BR /&gt;Thanks for your help! &lt;BR /&gt;</description>
      <pubDate>Thu, 10 Jul 2003 12:49:05 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91697#M142</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-10T12:49:05Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91698#M143</link>
      <description>I'm not sure what you're asking since you said you want to set the value via code but want to avoid scripting.  If you're not going to use scripting, what code are you referring to?  Do you mean set the value via code on the server?  If so, this will be a little tricky since the ActiveX controls are activated on the client.  You'll have to do something like what I mentioned in #2 in my last post in one of our &lt;A href="http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&amp;amp;RPAGEID=135&amp;amp;HOID=50650000000800000096760000&amp;amp;UCATEGORY_0=_47_%24_7_&amp;amp;UCATEGORY_S=0"&gt;previous threads&lt;/A&gt;.&lt;BR /&gt;&lt;BR /&gt;Just out of curiosity, why the aversion to scripting?  It's probably the easiest solution to what you wer&lt;BR /&gt;e asking and scripting should be supported on any browser that supports hosting ActiveX controls.&lt;BR /&gt;&lt;BR /&gt;- Elton &lt;BR /&gt;</description>
      <pubDate>Mon, 14 Jul 2003 02:17:55 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91698#M143</guid>
      <dc:creator>Elton Wells</dc:creator>
      <dc:date>2003-07-14T02:17:55Z</dc:date>
    </item>
    <item>
      <title>Re: ASP.NET (VB.NET) - cwui.ocx "errors loading control" error</title>
      <link>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91699#M144</link>
      <description>I'll script if it's the best solution. (This project needs to be done quickly and I didn't know if I had time to learn javascript. But, maybe it's worth the effort.)&lt;BR /&gt;&lt;BR /&gt;Once again, thanks for all of your help. You've been a valuable resource. &lt;BR /&gt;</description>
      <pubDate>Mon, 14 Jul 2003 12:13:59 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/Measurement-Studio-for-NET/ASP-NET-VB-NET-cwui-ocx-quot-errors-loading-control-quot-error/m-p/91699#M144</guid>
      <dc:creator>VB.NET/ASP.NET Programmer</dc:creator>
      <dc:date>2003-07-14T12:13:59Z</dc:date>
    </item>
  </channel>
</rss>

