Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB.NET 1.0 > Pro VB.NET 2002/2003
Pro VB.NET 2002/2003 For advanced Visual Basic coders working .NET version 2002/2003. Beginning-level questions will be redirected to other forums, including Beginning VB.NET.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB.NET 2002/2003 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 March 3rd, 2005, 02:45 AM
Registered User
Join Date: Mar 2005
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to arctica82
Default problem in showing froms by using names in VB.Net

I have used this code for showing forms by using their names.it works correctly when you are working in one project,but when you have more than one project in you solution and you want to show a form from one of the other projects(although I have added that reference to my project) it does not work the code is as fallows:

        Dim appName As String = Application.ProductName & "."
        Dim mForm As String = "Form3"
        Dim f As Form = DirectCast(Type.GetType(appName & mForm).InvokeMember(mForm, Reflection.BindingFlags.CreateInstance, Nothing, Nothing, Nothing), Form)

and the error is (object reference not set to an instance of object)

Old April 15th, 2005, 03:15 PM
Friend of Wrox
Join Date: Jul 2004
Posts: 623
Thanks: 0
Thanked 1 Time in 1 Post

cross post.

software student.

Similar Threads
Thread Thread Starter Forum Replies Last Post
VB Net Ms Access list column names (how to sample) jhkraft VB Databases Basics 2 March 13th, 2008 03:27 PM
froms through tab controls anukagni Access 1 October 3rd, 2006 06:39 AM
closing froms in while accesing other anukagni Access 4 May 11th, 2006 05:38 AM
Problem with Exercise in Beg. asp.net for VB.net! mrfella71 BOOK: Beginning ASP.NET 1.0 1 October 23rd, 2005 12:06 PM
Calling VB Procedure names from AccessTable akash VB How-To 4 April 12th, 2005 03:40 PM

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