ChildFormDialog unable to lookup my form


Author
Message
Chan
Chan
Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)
Group: Forum Members
Posts: 533, Visits: 2K
Hi,

I am facing problem that, ChildFormDialog unable to lookup my form class. I tried to change it namespace, class name, move it to another project, back to original project, still not help. It work if I use new statement.



Also, I found that, if I put my class in another project (which is BO library project, but used for UI) when debugging GetTypeFromReferencedAssemblies(_ChildForm), it even can't see my assembly.



ANy ideas?



Thank you
StrataFrame Team
S
StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
You can set the ChildForm property to the assembly qualified name of the type.  We generally only use the name of the type like this:

Namespace.FormTypeName

but if you change it to this:

Namespace.FormTypeName, AssemblyName, Version=X.0.0.0, Culture=neutral, PublicKeyToken=null

which is the assembly qualified name, then it will be able to find it.  You can get the assembly qualified name by typing this in the watch window while debugging:

typeof(YourFormType).AssemblyQualifiedName

Chan
Chan
Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)Advanced StrataFrame User (701 reputation)
Group: Forum Members
Posts: 533, Visits: 2K
Hi,

It works using AssemblyQualifiedName.



May I know your plan to solve it in next SF version?



Thank you
StrataFrame Team
S
StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)StrataFrame Developer (4.2K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
When we have issues like this in the next sf version, we will change the designer's CodeDom so that it will use typeof(Namespace.Type) which compiles the type reference into the executable and the string typename will not be used.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search