Developing a WYSIWYG - IDE type application. How would you do it?

I

iKiLL

Hi all



I have been asked to develop a solution that is customisable by our clients.

It is supposed to run on the Windows Mobile 5.0 CF2.0 environment using
Merge Replication.



I have looked into allowing the creation of Addin's but that has been
rejected as it would require to much programming knowledge of a Dot.Net
Language.



Ideally what I would like is to store the user interfaces and logical code
in a Database and then almost compile it at runtime to display the screens
and perform logical tasks.

Then build a WYSIWYG designer for creating the PDA entry screens that can
then almost be data bound.

What I am looking for is something like how an MS Access Database does where
you can do simple data bound screens or you can get into the thick of it and
write VB code.



My questions are:

1.. How do I store logical code in the database and then us it at runtime?
2.. Any ideas about how to build a WYSIWYG designer with a code editing
window?


If you know of any examples that would lead me in the right direction I
would be most great full.

The primary language I want to use for development is C#.



Thanks for any help.

ink
 
N

Neil Cowburn

This is something that's not really feasible with the .NET Compact and there
are a number of reasons why. The first being that the .NET Compact Framework
does not support CodeDOM or Reflection.Emit, so there is no way to
dynamically parse or generate IL instructions on the fly. Another being that
the .NET CF does not support drag & drop, so even if you did have a UI
designer running on the device, it would be cumbersome to work as there
would be no easy way to lay out the controls.

As a suggestion, you may want to propose to your client that they should use
templated forms. By that I mean construct a set of fairly generic UIs that
the user can choose from at runtime. These could include a single data row
UI, a tabular UI using the datagrid, or a master/detail view using a
combination of the previous two UIs.

--
Neil Cowburn
Principal Partner
OpenNETCF Consulting, LLC.

http://www.opennetcf.com/
 
I

iKiLL

Thank you all for your comments.

Fabrizio: This is a very interesting site. and i have downloaded the PDF. i
have read the intro and you are wright. This is alot more complicated than i
need, but this would be like the whole grail of what i need. but again. I am
looking to develop something that a User can be trained in one day to change
screen lay out but a developer can sink his teeth into if needs be, but
prioraty number one is simple user customisations.

Neil: It is verry interesting to know the limitations of .Net CF. But I am
sorry i did not explain my self clearly. but the Development environment
would be on a Desk to PC and Saved to the Publiser database and then synced
to the PDA via Merge replication. Then when the user logs into the app in
the PDA the app will read the screen layout from a Meta data table and draw
it.


Amit: I am still reading the link you sent me.

Thank you all for your comments.

ink
 
F

Fabrizio

I knew that. But it's useful to look at how someone did something like what
you have to do if you don't have any idea on how to do it.
I'm not particularly expert in this case, so I just suggested SharpDevelop
because is quite nice and most of all it is free and documented and you can
also download the source files, with the hope that the op would have found
something useful for him.
cheers
 
N

Neil Cowburn

OK, fair enough. You didn't mention that requirement, but you did state it
is "supposed to run on the Windows Mobile 5.0 CF2.0 environment using Merge
Replication".

It is possible to use a runtime interpreter to take some layout definition
and then construct a UI from that, but it would pretty much be a
display-only interface. How are you going to handle events? There is no
support for dynamic methods in the .NET CF so you cannot hook up a custom
event handler without pre-compiling the code.

--Neil

--
Neil Cowburn
Principal Partner
OpenNETCF Consulting, LLC.

http://www.opennetcf.com/
 
I

iKiLL

Thanks Neil,

What do you mean by "runtime interpreter" is this something i would purchase
or i would write.

i want to use C# to build this application but i dont mind if the users of
it use somethin like VB. infact this would probably be prefered for ease of
learning for the user.


Thanks
ink
 
G

Guest

This really is not something that's going to be easy. One of the problems,
as Neils has alluded to, is events. Let's say you spend a few months
getting a WYSIWYG editor (and I think that's generous). Now let's say a
user drops a button on a form. They'll want to handle a "cick" event
somehow. Well in order for that to happen, a handler would have to exist,
so you must already have a handler written and compiled into your code. You
don't have codedom to create one dynamically and you don't have a compiler
to make a new one.

To be honest, a full UI editor with teh code facilities would likely take
over a year to build. I'd also recommend you go with templates that can be
modified.
 
I

iKiLL

Thanks for Everyone's input.



i think i am beginning to see a pattern.



It is possible but very improbable.



i suppose i could try the Avango approach and create a Browser application
that dynamically generates the HTML from a Database. Or even holds the full
HTML/ASP pages in the database. Kind of like having a small local website on
the PDA that communicates with the Local SQL Mobile DB.

But then i would still need some kind of server to Process the Dynamic pages
and there data.



Do you think this would be a possibility?



ink
 
G

Guest

HTML is definitely going to be easier to generate, but then the challenge is
talking to the database. I'd guess you'd want to create an ActiveX control
to provide that data interaction. Not too difficult, but it would have to
be C++.
 
N

Neil Cowburn

Using C++ and ActiveX is not the only solution. You could create an app in
C# that uses the WebBrowser control from the .NET Compact Framework. The app
would pull the data out of the database, generate the HTML and then display
that in the WebBrowser control. This would take you less time than it would
to learn C++ and the ActiveX technology.

--
Neil Cowburn
Principal Partner
OpenNETCF Consulting, LLC.

http://www.opennetcf.com/
 
I

Ignacio Machin \( .NET/ C# MVP \)

Hi,

iKiLL said:
Thank you all for your comments.
Amit: I am still reading the link you sent me.


I just want to point out that any solution you find will require a DEEP
knowledge of C# and the .net framework
 
I

iKiLL

this is exactly what i was thinking of doing.

But i would still have to handle the Saving of data on the Form submits.
I have not used the browser control since my VB6 days so i am not sure what
events there are now so i will have to do some playing.

Thanks for all your input.
 
G

Guest

By the time you have this working, I guarantee you *will* have a deep
understanding. No way you'll get it done otherwise.
 
G

Guest

Check out XS Forms and XS Designer at http://www.grandasoft.com/

It fits your criteria -- design the forms on your desktop computer, deploy
them to the devices for data gathering, and then upload the information back
to the desktop. It's free for personal use, and can be licensed for
professional use.

It's drag and drop for the form designer, and also allows for scripting
(vbscript and jscript) for developers. You can also write queries to be run
on the device for simple display reports.

Flynn
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top