Wrox Programmer Forums
|
BOOK: Visual Basic 2008 Programmer's Reference ISBN: 978-0-470-18262-8
This is the forum to discuss the Wrox book Visual Basic 2008 Programmer's Reference by Rod Stephens; ISBN: 9780470182628
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Visual Basic 2008 Programmer's Reference ISBN: 978-0-470-18262-8 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 9th, 2010, 07:55 PM
Registered User
 
Join Date: Jun 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Runtime instance of a usercontrol

In vb.net 2005, I have created a custom user control. The control works quite well at design time and at run time. However, if I try to "create" an instance of the control at run time (dim ctl = new foo()), This gives an error "type needed". In the intellisense autocomplete, it shows the "foo" object with an icon that looks like pair of brackets {}. any idea what I did wrong?
 
Old June 9th, 2010, 10:42 PM
Rod Stephens's Avatar
Wrox Author
 
Join Date: Jan 2006
Posts: 647
Thanks: 2
Thanked 96 Times in 95 Posts
Default Braces mean namespace

In IntelliSense, the {} braces mean a namespace. For example, if you type "Sys" you should see "{}System" in the IntelliSense list.

Probably this means you have your control in its own namespace. A Foo control inside the Foo namespace. If that's the case, then you should be able to create an instance of Foo.Foo.
__________________
Rod

Rod Stephens, Microsoft MVP

Essential Algorithms: A Practical Approach to Computer Algorithms

(Please post reviews at Amazon or wherever you shop!)





Similar Threads
Thread Thread Starter Forum Replies Last Post
UserControl in a GridView Aaron Edwards ASP.NET 2.0 Professional 0 November 22nd, 2007 01:00 PM
ArrayList with UserControl rhd110 General .NET 2 August 12th, 2007 12:29 PM
how to make usercontrol touyakira Visual C++ 2005 0 May 17th, 2006 10:13 PM
Intellisense for UserControl RNedel ASP.NET 1.0 and 1.1 Basics 6 June 15th, 2004 04:47 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.