when i pass a "Type", Console.write() prints System.Runtime?


hi friends,

i have opened form counting method

int countopenedforms(type f)

{

      console.write(f.gettype().tostring());

}

when pass form type, assume project has form type called frmproducts, write() prints system.runtime. should print  <project_name>.frmproducts

why happens, how fix it?


i use visual studio 2010 professional , sql server 2008 developer edition!

hi sniff_bits;

i think may want following:

int countopenedforms(form f) {     console.write(f.gettype().tostring());     return 0; }

then call following:

// assuming form want count has // instance name theforminstance countopenedforms(theforminstance);

  


fernando (mcsd)

if post answers question, please click "mark answer" on post , "mark helpful".

note: if ask code, please provide can drop directly project , run (including xaml), or actual application project. i'm trying lot of people, don't have time figure out weird snippets undefined objects , unknown namespaces.



Visual Studio Languages  ,  .NET Framework  >  Visual C#



Comments

Popular posts from this blog

Azure DocumentDB Owner resource does not exist

job syspolicy_purge_history job fail in sqlserver 2008

Trying to register with public marketplace error with 'Get-AzureStackStampInformation'