DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Thu, 9 Aug 2007 20:09:38 +0100,    posted on: microsoft.public.dotnet.framework.compactframework        back       

Thread Index
  1    ink
          2    dbgrick
                 3    ink
                        4    ctacke/ ctacke[at]opennetcf[dot]com
                               5    ink


Automating a CF2 App???   
Hi all,

I am relatively new to C# and the CF, as a whole I have about 8 months 
experience with then so not a great deal. I come from a VB6 back ground so 
my OOP and Threading are also new to me. I am having a problem with an 
application I am trying to write and you seem to be some what of a guru on 
the topic of CF development, so I would be very great full for any help or 
advice you could give me.

What I am trying to do is write an application that will automat UAT tests 
for my company. We tend to develop high volume user applications for 
warehouses and proof of delivery systems. These are all running on Windows 
Mobile devices from Symbol.

The problem is trying to run suitable load and regression tests on 800 units 
at a time is virtually imposable. So what I am trying to write is a small 
application that can drive the main application from a simple text file, 
like a test script.

I found what I thought was a fantastic solution to my problem at this 
website.
http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx

I ported the 2 Applications in the article to CF2 applications.

However I seem to have come up against a few hurdles to do with the loading 
of the the application I am trying to test. In CF7 applications there is a 
Static Program class that is the entry point with a private method Main.

I have tried a number of different ways of invoke this method to get the 
application to load up but I keep getting errors. I have even tried exposing 
a public method in the application I am trying to test and calling the main 
method from with in that but still no luck.

Any help would be fantastic.

Thanks,
Ink

PS below is some of the code I have tried.


private void button1_Click(object sender, EventArgs e)
        {

            //First load the application
            testAssembly = Assembly.LoadFrom("\\Program 
Files\\WM_Automation_Test\\WM_Automation_Test.exe");
            //Type t = testAssembly.GetType("Mnetics.CEApp.Splash");
            //testForm = (Form)testAssembly.CreateInstance(t.FullName);
            //Mnetics.CEApp.Forms.Splash
            //ChangeForm("Mnetics.CEApp.Forms.Splash");

            //Type t = testAssembly.GetType("WM_Automation_Test.Program");
            //t.GetMethod("AutomationEntry").Invoke(null, new object[] { });


            Type t = testAssembly.GetType("WM_Automation_Test.Program");

            t.GetMethod("AutomationEntry").Invoke(null, new object[] { });



            //object x = (object)testAssembly.CreateInstance(t.FullName);
            //InvokeMethod(x, "Main");
            //ThreadPool.QueueUserWorkItem(new WaitCallback(RunApp), 
testForm);


        }

        private void ChangeForm(string NewForm)
        {
            Type t = testAssembly.GetType(NewForm);
            testForm = (Form)testAssembly.CreateInstance(t.FullName);
        }

        //private delegate void RunAppDelegate(object state);

        static void RunApp(object state) // Need this function to pass into 
WaitCallback().
        {

            //if (this.InvokeRequired)
            //{
            //    // we were called on a worker thread
            //    // marshal the call to the user interface thread
            //    this.Invoke(new RunAppDelegate(RunApp), new object[] { 
state });
            //    return;
            //}

            // this code can only be reached
            // by the user interface thread

            //Start the application

            Application.Run((Form)state);


        }
Date:Thu, 9 Aug 2007 20:09:38 +0100   Author:  

RE: Automating a CF2 App???   
ink,
I had a large cf application that required monitoring and remote execution 
of code.  Initially I considered using .NET remoting, but instead wrote a 
telnet client that would stream results and allowed the user to send script 
type messages to the app.  This would allow you to execute your test code and 
retrieve results from your Mobile application.  Here is an article that gives 
you an idea of how to create the client on the Mobile Device.  I hope this 
helps.

http://www.codeproject.com/useritems/WiMoTelnetClient.asp

Rick D.
Contractor

"ink" wrote:


> Hi all,
> 
> I am relatively new to C# and the CF, as a whole I have about 8 months 
> experience with then so not a great deal. I come from a VB6 back ground so 
> my OOP and Threading are also new to me. I am having a problem with an 
> application I am trying to write and you seem to be some what of a guru on 
> the topic of CF development, so I would be very great full for any help or 
> advice you could give me.
> 
> What I am trying to do is write an application that will automat UAT tests 
> for my company. We tend to develop high volume user applications for 
> warehouses and proof of delivery systems. These are all running on Windows 
> Mobile devices from Symbol.
> 
> The problem is trying to run suitable load and regression tests on 800 units 
> at a time is virtually imposable. So what I am trying to write is a small 
> application that can drive the main application from a simple text file, 
> like a test script.
> 
> I found what I thought was a fantastic solution to my problem at this 
> website.
> http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx
> 
> I ported the 2 Applications in the article to CF2 applications.
> 
> However I seem to have come up against a few hurdles to do with the loading 
> of the the application I am trying to test. In CF7 applications there is a 
> Static Program class that is the entry point with a private method Main.
> 
> I have tried a number of different ways of invoke this method to get the 
> application to load up but I keep getting errors. I have even tried exposing 
> a public method in the application I am trying to test and calling the main 
> method from with in that but still no luck.
> 
> Any help would be fantastic.
> 
> Thanks,
> Ink
> 
> PS below is some of the code I have tried.
> 
> 
> private void button1_Click(object sender, EventArgs e)
>         {
> 
>             //First load the application
>             testAssembly = Assembly.LoadFrom("\\Program 
> Files\\WM_Automation_Test\\WM_Automation_Test.exe");
>             //Type t = testAssembly.GetType("Mnetics.CEApp.Splash");
>             //testForm = (Form)testAssembly.CreateInstance(t.FullName);
>             //Mnetics.CEApp.Forms.Splash
>             //ChangeForm("Mnetics.CEApp.Forms.Splash");
> 
>             //Type t = testAssembly.GetType("WM_Automation_Test.Program");
>             //t.GetMethod("AutomationEntry").Invoke(null, new object[] { });
> 
> 
>             Type t = testAssembly.GetType("WM_Automation_Test.Program");
> 
>             t.GetMethod("AutomationEntry").Invoke(null, new object[] { });
> 
> 
> 
>             //object x = (object)testAssembly.CreateInstance(t.FullName);
>             //InvokeMethod(x, "Main");
>             //ThreadPool.QueueUserWorkItem(new WaitCallback(RunApp), 
> testForm);
> 
> 
>         }
> 
>         private void ChangeForm(string NewForm)
>         {
>             Type t = testAssembly.GetType(NewForm);
>             testForm = (Form)testAssembly.CreateInstance(t.FullName);
>         }
> 
>         //private delegate void RunAppDelegate(object state);
> 
>         static void RunApp(object state) // Need this function to pass into 
> WaitCallback().
>         {
> 
>             //if (this.InvokeRequired)
>             //{
>             //    // we were called on a worker thread
>             //    // marshal the call to the user interface thread
>             //    this.Invoke(new RunAppDelegate(RunApp), new object[] { 
> state });
>             //    return;
>             //}
> 
>             // this code can only be reached
>             // by the user interface thread
> 
>             //Start the application
> 
>             Application.Run((Form)state);
> 
> 
>         }
> 
> 
> 
Date:Thu, 9 Aug 2007 14:08:04 -0700   Author:  

Re: Automating a CF2 App???   
Hi dbgrick,
Thanks for your help. This is a very interesting article and I intend on 
playing with it a bit.
And my apologies for not making my problem very clear.
The problem I am having is trying to load up a Dot.net application in the 
same thread as the calling application so that I can use reflection to call 
into the procedures of that application.
Thanks,
ink




"dbgrick"  wrote in message 
news:AE8B3F3B-4488-4287-B21E-FB5F35DDAD16@microsoft.com...

> ink,
> I had a large cf application that required monitoring and remote execution
> of code.  Initially I considered using .NET remoting, but instead wrote a
> telnet client that would stream results and allowed the user to send 
> script
> type messages to the app.  This would allow you to execute your test code 
> and
> retrieve results from your Mobile application.  Here is an article that 
> gives
> you an idea of how to create the client on the Mobile Device.  I hope this
> helps.
>
> http://www.codeproject.com/useritems/WiMoTelnetClient.asp
>
> Rick D.
> Contractor
>
> "ink" wrote:
>
>> Hi all,
>>
>> I am relatively new to C# and the CF, as a whole I have about 8 months
>> experience with then so not a great deal. I come from a VB6 back ground 
>> so
>> my OOP and Threading are also new to me. I am having a problem with an
>> application I am trying to write and you seem to be some what of a guru 
>> on
>> the topic of CF development, so I would be very great full for any help 
>> or
>> advice you could give me.
>>
>> What I am trying to do is write an application that will automat UAT 
>> tests
>> for my company. We tend to develop high volume user applications for
>> warehouses and proof of delivery systems. These are all running on 
>> Windows
>> Mobile devices from Symbol.
>>
>> The problem is trying to run suitable load and regression tests on 800 
>> units
>> at a time is virtually imposable. So what I am trying to write is a small
>> application that can drive the main application from a simple text file,
>> like a test script.
>>
>> I found what I thought was a fantastic solution to my problem at this
>> website.
>> http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx
>>
>> I ported the 2 Applications in the article to CF2 applications.
>>
>> However I seem to have come up against a few hurdles to do with the 
>> loading
>> of the the application I am trying to test. In CF7 applications there is 
>> a
>> Static Program class that is the entry point with a private method Main.
>>
>> I have tried a number of different ways of invoke this method to get the
>> application to load up but I keep getting errors. I have even tried 
>> exposing
>> a public method in the application I am trying to test and calling the 
>> main
>> method from with in that but still no luck.
>>
>> Any help would be fantastic.
>>
>> Thanks,
>> Ink
>>
>> PS below is some of the code I have tried.
>>
>>
>> private void button1_Click(object sender, EventArgs e)
>>         {
>>
>>             //First load the application
>>             testAssembly = Assembly.LoadFrom("\\Program
>> Files\\WM_Automation_Test\\WM_Automation_Test.exe");
>>             //Type t = testAssembly.GetType("Mnetics.CEApp.Splash");
>>             //testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>             //Mnetics.CEApp.Forms.Splash
>>             //ChangeForm("Mnetics.CEApp.Forms.Splash");
>>
>>             //Type t = 
>> testAssembly.GetType("WM_Automation_Test.Program");
>>             //t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>> { });
>>
>>
>>             Type t = testAssembly.GetType("WM_Automation_Test.Program");
>>
>>             t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>> { });
>>
>>
>>
>>             //object x = (object)testAssembly.CreateInstance(t.FullName);
>>             //InvokeMethod(x, "Main");
>>             //ThreadPool.QueueUserWorkItem(new WaitCallback(RunApp),
>> testForm);
>>
>>
>>         }
>>
>>         private void ChangeForm(string NewForm)
>>         {
>>             Type t = testAssembly.GetType(NewForm);
>>             testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>         }
>>
>>         //private delegate void RunAppDelegate(object state);
>>
>>         static void RunApp(object state) // Need this function to pass 
>> into
>> WaitCallback().
>>         {
>>
>>             //if (this.InvokeRequired)
>>             //{
>>             //    // we were called on a worker thread
>>             //    // marshal the call to the user interface thread
>>             //    this.Invoke(new RunAppDelegate(RunApp), new object[] {
>> state });
>>             //    return;
>>             //}
>>
>>             // this code can only be reached
>>             // by the user interface thread
>>
>>             //Start the application
>>
>>             Application.Run((Form)state);
>>
>>
>>         }
>>
>>
>> 
Date:Fri, 10 Aug 2007 08:53:01 +0100   Author:  

Re: Automating a CF2 App???   
You can't load 2 applications into 1 thread (as I explained in the other NG 
thread you started).  If you simply want to call methods in the other 
application then you can use Reflection to create instances of classes. 
However this is not going to get you the results you want of a separate UI 
running since there can't be 2 message pumps running in a single 
application.

If you need to launch some other app and affect its UI - clicking buttons, 
entering text, etc then you need to simulate user input by calling 
mouse_event/SetCursorPos/keybd_event/PostKeyboardMessage and things like 
that.


-- 

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Managed Code in an Embedded World
www.OpenNETCF.com



"ink"  wrote in message 
news:uE9rCOy2HHA.1484@TK2MSFTNGP06.phx.gbl...

>
> Hi dbgrick,
> Thanks for your help. This is a very interesting article and I intend on 
> playing with it a bit.
> And my apologies for not making my problem very clear.
> The problem I am having is trying to load up a Dot.net application in the 
> same thread as the calling application so that I can use reflection to 
> call into the procedures of that application.
> Thanks,
> ink
>
>
>
>
> "dbgrick"  wrote in message 
> news:AE8B3F3B-4488-4287-B21E-FB5F35DDAD16@microsoft.com...
>> ink,
>> I had a large cf application that required monitoring and remote 
>> execution
>> of code.  Initially I considered using .NET remoting, but instead wrote a
>> telnet client that would stream results and allowed the user to send 
>> script
>> type messages to the app.  This would allow you to execute your test code 
>> and
>> retrieve results from your Mobile application.  Here is an article that 
>> gives
>> you an idea of how to create the client on the Mobile Device.  I hope 
>> this
>> helps.
>>
>> http://www.codeproject.com/useritems/WiMoTelnetClient.asp
>>
>> Rick D.
>> Contractor
>>
>> "ink" wrote:
>>
>>> Hi all,
>>>
>>> I am relatively new to C# and the CF, as a whole I have about 8 months
>>> experience with then so not a great deal. I come from a VB6 back ground 
>>> so
>>> my OOP and Threading are also new to me. I am having a problem with an
>>> application I am trying to write and you seem to be some what of a guru 
>>> on
>>> the topic of CF development, so I would be very great full for any help 
>>> or
>>> advice you could give me.
>>>
>>> What I am trying to do is write an application that will automat UAT 
>>> tests
>>> for my company. We tend to develop high volume user applications for
>>> warehouses and proof of delivery systems. These are all running on 
>>> Windows
>>> Mobile devices from Symbol.
>>>
>>> The problem is trying to run suitable load and regression tests on 800 
>>> units
>>> at a time is virtually imposable. So what I am trying to write is a 
>>> small
>>> application that can drive the main application from a simple text file,
>>> like a test script.
>>>
>>> I found what I thought was a fantastic solution to my problem at this
>>> website.
>>> http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx
>>>
>>> I ported the 2 Applications in the article to CF2 applications.
>>>
>>> However I seem to have come up against a few hurdles to do with the 
>>> loading
>>> of the the application I am trying to test. In CF7 applications there is 
>>> a
>>> Static Program class that is the entry point with a private method Main.
>>>
>>> I have tried a number of different ways of invoke this method to get the
>>> application to load up but I keep getting errors. I have even tried 
>>> exposing
>>> a public method in the application I am trying to test and calling the 
>>> main
>>> method from with in that but still no luck.
>>>
>>> Any help would be fantastic.
>>>
>>> Thanks,
>>> Ink
>>>
>>> PS below is some of the code I have tried.
>>>
>>>
>>> private void button1_Click(object sender, EventArgs e)
>>>         {
>>>
>>>             //First load the application
>>>             testAssembly = Assembly.LoadFrom("\\Program
>>> Files\\WM_Automation_Test\\WM_Automation_Test.exe");
>>>             //Type t = testAssembly.GetType("Mnetics.CEApp.Splash");
>>>             //testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>>             //Mnetics.CEApp.Forms.Splash
>>>             //ChangeForm("Mnetics.CEApp.Forms.Splash");
>>>
>>>             //Type t = 
>>> testAssembly.GetType("WM_Automation_Test.Program");
>>>             //t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>>> { });
>>>
>>>
>>>             Type t = testAssembly.GetType("WM_Automation_Test.Program");
>>>
>>>             t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>>> { });
>>>
>>>
>>>
>>>             //object x = 
>>> (object)testAssembly.CreateInstance(t.FullName);
>>>             //InvokeMethod(x, "Main");
>>>             //ThreadPool.QueueUserWorkItem(new WaitCallback(RunApp),
>>> testForm);
>>>
>>>
>>>         }
>>>
>>>         private void ChangeForm(string NewForm)
>>>         {
>>>             Type t = testAssembly.GetType(NewForm);
>>>             testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>>         }
>>>
>>>         //private delegate void RunAppDelegate(object state);
>>>
>>>         static void RunApp(object state) // Need this function to pass 
>>> into
>>> WaitCallback().
>>>         {
>>>
>>>             //if (this.InvokeRequired)
>>>             //{
>>>             //    // we were called on a worker thread
>>>             //    // marshal the call to the user interface thread
>>>             //    this.Invoke(new RunAppDelegate(RunApp), new object[] {
>>> state });
>>>             //    return;
>>>             //}
>>>
>>>             // this code can only be reached
>>>             // by the user interface thread
>>>
>>>             //Start the application
>>>
>>>             Application.Run((Form)state);
>>>
>>>
>>>         }
>>>
>>>
>>>
> 
Date:Fri, 10 Aug 2007 07:20:24 -0500   Author:  

Re: Automating a CF2 App???   
Hi,

I see. i am just not understand how come the application on the Microsoft 
website seems to do what i need it to do.

Will this only work with a single form application?
So that you can create the instance of the form your self rather than 
letting the application do it. And then call its methods.


http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx


thanks,
ink




"<ctacke/>" <ctacke[at]opennetcf[dot]com> wrote in message 
news:e7iPkj02HHA.484@TK2MSFTNGP06.phx.gbl...

> You can't load 2 applications into 1 thread (as I explained in the other 
> NG thread you started).  If you simply want to call methods in the other 
> application then you can use Reflection to create instances of classes. 
> However this is not going to get you the results you want of a separate UI 
> running since there can't be 2 message pumps running in a single 
> application.
>
> If you need to launch some other app and affect its UI - clicking buttons, 
> entering text, etc then you need to simulate user input by calling 
> mouse_event/SetCursorPos/keybd_event/PostKeyboardMessage and things like 
> that.
>
>
> -- 
>
> Chris Tacke, Embedded MVP
> OpenNETCF Consulting
> Managed Code in an Embedded World
> www.OpenNETCF.com
>
>
>
> "ink"  wrote in message 
> news:uE9rCOy2HHA.1484@TK2MSFTNGP06.phx.gbl...
>>
>> Hi dbgrick,
>> Thanks for your help. This is a very interesting article and I intend on 
>> playing with it a bit.
>> And my apologies for not making my problem very clear.
>> The problem I am having is trying to load up a Dot.net application in the 
>> same thread as the calling application so that I can use reflection to 
>> call into the procedures of that application.
>> Thanks,
>> ink
>>
>>
>>
>>
>> "dbgrick"  wrote in message 
>> news:AE8B3F3B-4488-4287-B21E-FB5F35DDAD16@microsoft.com...
>>> ink,
>>> I had a large cf application that required monitoring and remote 
>>> execution
>>> of code.  Initially I considered using .NET remoting, but instead wrote 
>>> a
>>> telnet client that would stream results and allowed the user to send 
>>> script
>>> type messages to the app.  This would allow you to execute your test 
>>> code and
>>> retrieve results from your Mobile application.  Here is an article that 
>>> gives
>>> you an idea of how to create the client on the Mobile Device.  I hope 
>>> this
>>> helps.
>>>
>>> http://www.codeproject.com/useritems/WiMoTelnetClient.asp
>>>
>>> Rick D.
>>> Contractor
>>>
>>> "ink" wrote:
>>>
>>>> Hi all,
>>>>
>>>> I am relatively new to C# and the CF, as a whole I have about 8 months
>>>> experience with then so not a great deal. I come from a VB6 back ground 
>>>> so
>>>> my OOP and Threading are also new to me. I am having a problem with an
>>>> application I am trying to write and you seem to be some what of a guru 
>>>> on
>>>> the topic of CF development, so I would be very great full for any help 
>>>> or
>>>> advice you could give me.
>>>>
>>>> What I am trying to do is write an application that will automat UAT 
>>>> tests
>>>> for my company. We tend to develop high volume user applications for
>>>> warehouses and proof of delivery systems. These are all running on 
>>>> Windows
>>>> Mobile devices from Symbol.
>>>>
>>>> The problem is trying to run suitable load and regression tests on 800 
>>>> units
>>>> at a time is virtually imposable. So what I am trying to write is a 
>>>> small
>>>> application that can drive the main application from a simple text 
>>>> file,
>>>> like a test script.
>>>>
>>>> I found what I thought was a fantastic solution to my problem at this
>>>> website.
>>>> http://msdn.microsoft.com/msdnmag/issues/03/01/UITestAutomation/default.aspx
>>>>
>>>> I ported the 2 Applications in the article to CF2 applications.
>>>>
>>>> However I seem to have come up against a few hurdles to do with the 
>>>> loading
>>>> of the the application I am trying to test. In CF7 applications there 
>>>> is a
>>>> Static Program class that is the entry point with a private method 
>>>> Main.
>>>>
>>>> I have tried a number of different ways of invoke this method to get 
>>>> the
>>>> application to load up but I keep getting errors. I have even tried 
>>>> exposing
>>>> a public method in the application I am trying to test and calling the 
>>>> main
>>>> method from with in that but still no luck.
>>>>
>>>> Any help would be fantastic.
>>>>
>>>> Thanks,
>>>> Ink
>>>>
>>>> PS below is some of the code I have tried.
>>>>
>>>>
>>>> private void button1_Click(object sender, EventArgs e)
>>>>         {
>>>>
>>>>             //First load the application
>>>>             testAssembly = Assembly.LoadFrom("\\Program
>>>> Files\\WM_Automation_Test\\WM_Automation_Test.exe");
>>>>             //Type t = testAssembly.GetType("Mnetics.CEApp.Splash");
>>>>             //testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>>>             //Mnetics.CEApp.Forms.Splash
>>>>             //ChangeForm("Mnetics.CEApp.Forms.Splash");
>>>>
>>>>             //Type t = 
>>>> testAssembly.GetType("WM_Automation_Test.Program");
>>>>             //t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>>>> { });
>>>>
>>>>
>>>>             Type t = 
>>>> testAssembly.GetType("WM_Automation_Test.Program");
>>>>
>>>>             t.GetMethod("AutomationEntry").Invoke(null, new object[] 
>>>> { });
>>>>
>>>>
>>>>
>>>>             //object x = 
>>>> (object)testAssembly.CreateInstance(t.FullName);
>>>>             //InvokeMethod(x, "Main");
>>>>             //ThreadPool.QueueUserWorkItem(new WaitCallback(RunApp),
>>>> testForm);
>>>>
>>>>
>>>>         }
>>>>
>>>>         private void ChangeForm(string NewForm)
>>>>         {
>>>>             Type t = testAssembly.GetType(NewForm);
>>>>             testForm = (Form)testAssembly.CreateInstance(t.FullName);
>>>>         }
>>>>
>>>>         //private delegate void RunAppDelegate(object state);
>>>>
>>>>         static void RunApp(object state) // Need this function to pass 
>>>> into
>>>> WaitCallback().
>>>>         {
>>>>
>>>>             //if (this.InvokeRequired)
>>>>             //{
>>>>             //    // we were called on a worker thread
>>>>             //    // marshal the call to the user interface thread
>>>>             //    this.Invoke(new RunAppDelegate(RunApp), new object[] 
>>>> {
>>>> state });
>>>>             //    return;
>>>>             //}
>>>>
>>>>             // this code can only be reached
>>>>             // by the user interface thread
>>>>
>>>>             //Start the application
>>>>
>>>>             Application.Run((Form)state);
>>>>
>>>>
>>>>         }
>>>>
>>>>
>>>>
>>
>
> 
Date:Fri, 10 Aug 2007 14:43:39 +0100   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us