PDA

View Full Version : Chat with other VFP developers on how to migrate VFP applications



barrymavin
2012-10-27, 03:29
This is the place to talk about migrating existing VFP code into Lianja. Chat with other VFP developers and gain a better understanding of how to migrate VFP applications into Lianja.

rprieto
2012-11-25, 15:21
Hello I´m new in Lianja, we have an aplication in VisualFox 9.0 , I´m trying to migrate to Lianja, first I begin with a simple program that execute a form and scx, and doesn´t work I try tu run the form directo from the console and doesn´t work, I import de dbf files in database If i generate a page from lianja it work fine, but with the forms that I import doesn´t work , any tips , thanks in advance

lianjasupport
2012-11-25, 20:32
Hi @rprieto Did you import the .scx file? If you did you will have a .scp file in your App folder. You can just run the form using the "do" command from the console.

However, there was an issue importing scx files correctly in Beta10 which we have fixed in Beta11 which we expect to release soon.

After you have tested that your form displays and works as expected in the console. you can then "embed" the form inside a "Custom Section" in a "page" in the "page attributes" dialog.

rprieto
2012-11-26, 16:49
Yes I import the scx files but when i try to run the form i have and error , send you and output from the error....

lianjasupport
2012-11-26, 22:23
Yes I import the scx files but when i try to run the form i have and error , send you and output from the error....

Can you submit a ticket at http://www.lianja.com/support/newticket and attach the .scp file so we can take a look at this issue.

This may have been fixed in the latest build so we will test and see.

douglasg76
2012-12-10, 12:20
Hello, Lianja support team, I m trying to migrate to Lianja, but when I drop my *.pjx onto "Apps" panel in the "Apps" workspace, but Nothing happens, What am I doing wrong?
Thank
Douglas.Sanchez

lianjasupport
2012-12-10, 12:27
Hi Douglas,
Make sure you have an App open, then drag and drop the pjx file into the 'Files' section of the Apps sidebar.

douglasg76
2012-12-10, 12:42
Do you have any video of the steps to be followed.

1 Create a NEW APP BLANK.

2 Open the app Lianja_tester

3 drop the *.pjx onto my new proyect lianja tester.

That all, hellp me, What am I doing wrong?

lianjasupport
2012-12-10, 12:48
No video at the moment. You can see a screenshot here: http://www.lianja.com/documentation/documentation-index/307-importing-visual-FoxPro-files. Are you dropping it in the 'Files' section? Do you get any output in the Console Workspace Output Window?

douglasg76
2012-12-10, 12:55
I do, now, only import the dbc database from vfp, but the project *.pjx and form, I cant do it yet.

lianjasupport
2012-12-10, 12:59
I do, now, only import the dbc database from vfp, but the project *.pjx and form, I cant do it yet.

This is a screen shot of what you need to do: http://www.lianja.com/images/stories/tutorials/import_vfp/drag_pjx.png

Please make sure that you are in the "Apps" workspace as selected from the left side of the screen.

johnnywild
2012-12-18, 16:41
Tried to import a VFP project today using the Importing Visual FoxPro file document with no luck at all. Using latest RC1 build. Followed the exact instructions. Created a New project, brought up Explorer (using Windows 7) and selected the PJX file and dragged it into the Files section. The cursor changed to a [+] sign and I got a message in top right corner that the Project Import Completed. No files were converted or transferred.

The VFP 9 project is an active real project and has no issues when opened in VFP 9. The files contained in the project are all in sub directories off the main project directory but there are some common library files that are up several directory levels but on the same Drive. Not sure what to do next...

Thanks

johnnywild
2012-12-18, 17:46
Since the project would not import I used the individual VCX import. This worked but when I reviewed the code I see that most All control classes are defined from their 'baseclass' and not the 'parent class', for example, all textboxes are 'textbox' instead of deriving the parent class from a class library file that was imported prior. This project uses the FoxPro framework 'CodeBook' and ALL textboxes are defined in that framework as textbox --> aSecureTextbox. The aSecureTextbox is defined in a VCX file named aSecCtrl.vcx. I import this first then I imported the vcx file that depends on the control class definitions. When I reviewed the imported code, the textbox, labels, cbobox, etc all were derived from VFP base classes and not the parent class definition from aSecCtrl.vcx.

When I bring the vcx form up in VFP and select a textbox, the properties show the proper hierarchy and references the Class as aSecureTextbox and the ClassLibrary is ..\iLibs\aSecCtrl.vcx.

Am I doing this right? Since there is no real documentation on how to actually get a real VFP app project imported and up and running that I can find, this is really a major trial and mostly error project so far. Help...

barrymavin
2012-12-18, 20:23
The issue regarding classnames was reported by another developer and has been fixed in RC2. We will take a look at subclassed vcx controls but it may not be in v1.0 as we are trying to stick to the roadmap and many devs are waiting for us to release it as they have customers waiting to purchase.

It will get fixed in due course.

johnnywild
2012-12-19, 10:50
Wow, this is so fundamental to our projects that this limitation will be a major show-stopper for us in using Lianja. We have always had common sub-classes for controls in all of our projects. It is odd that this was missed since it is what VFP is so powerful at. I don't see how any VFP project could be converted other than very very simple forms and code that only uses VFP base classes. I do hope this fix will be in RC2 soon. Please!

It appears that the sub-class name is being used as part of the converted class name. I suggest using the control name as the class name instead...
Example:
define class asecuretextbox_10m0swb41_10m0swb41 as textbox (suggest using Name for the class: define class txtcTitle_10m0swb41 as asecuretextbox)

** Properties
....
Name = "txtcTitle"
...
enddefine

You can see that this textbox definition actually does show the sub-class name 'asecuretextbox' but uses it as part of the name of the class! Also not sure why the 10m0swb41 is repeated in the name.

Thanks Barry for responding to this quickly!

barrymavin
2012-12-19, 11:06
It's not as straightforward as that. Nevertheless submit a ticket and attach the scx and vcx files and let me look at it. RC2 is almost ready to release and as you know the holidays are fast approaching so it's unlikely to be in that.

HankFay
2012-12-19, 18:12
Wow, this is so fundamental to our projects that this limitation will be a major show-stopper for us in using Lianja. We have always had common sub-classes for controls in all of our projects. It is odd that this was missed since it is what VFP is so powerful at. I don't see how any VFP project could be converted other than very very simple forms and code that only uses VFP base classes. I do hope this fix will be in RC2 soon. Please!

It appears that the sub-class name is being used as part of the converted class name. I suggest using the control name as the class name instead...
Example:
define class asecuretextbox_10m0swb41_10m0swb41 as textbox (suggest using Name for the class: define class txtcTitle_10m0swb41 as asecuretextbox)

** Properties
....
Name = "txtcTitle"
...
enddefine

You can see that this textbox definition actually does show the sub-class name 'asecuretextbox' but uses it as part of the name of the class! Also not sure why the 10m0swb41 is repeated in the name.

Thanks Barry for responding to this quickly!

Hi John,

we subclassed all controls likewise. That said, if VFP had VFP interfaces, we would have done an IMPLEMENTS in the classes of the various controls, because we ended up adding a bunch of identical functionality to all the UI controls (and then specific stuff after that). And of course in Lianja, we have the option of changing functionality at runtime, since a method can be set to a prg, etc.

IOW, I'm keeping my mind and options open for how we will do it in Lianja. There are many variables: e.g., what is the inheritance hierarchy, if any, between Control and, say, Combobox? What is the penalty for subclassing (VFP was a two-pass compiler, so empty methods in the hierarchy impose no penalty -- measured it; Lianja is a JIT compiler)? What the is program bloat for sublcassing (important perhaps, but we haven't had a chance to measure it yet of course, when doing Native Mobile)? And these are just the questions off the top of my head; I imagine Barry has a larger set of considerations in mind when he says it's not as simple as it seems. That said, he's been coming through for us this long now, so I'm not concerned about where we'll end up.

Fortunately, for our first commercial project in Lianja we won't have to do that much, and can get away with control modification at runtime, which we will make as painless as using a subclass (by using a re-entrant builder to set the mods, which we would create anyway to set properties on the subclass). As with all our tools, we'll put what we build with this out on LianjaX.

Hank

barrymavin
2012-12-19, 19:34
The class naming is already fixed in RC2. This was broken during one of the betas.

barrymavin
2012-12-19, 20:17
The good news is that the importer is all written in Lianja/VFP scripting and resides in the library directory so even after RC2 is released we can adjust this to generate the handling of subclasssed controls without having to release new distributions.

barrymavin
2012-12-20, 01:22
This has now been fixed in RC2.

Don't forget that VFP .vcx class libraries get imported as '.vcp' files and thats what SET CLASSLIB TO expects.

After you import an .scx file (or multiples of them when a .pjx is imported) you can use the CREATEOBJECT() function on the classes in the class libraries or you can just instantiate a GUI form using:

do form name_of_form

You can also embed these into a "custom" section so that the form occupies a "page" in Lianja. Remember to check the "Stretch last section" attribute in the section attributes.

This will allow you to navigate back and forwards between pages without losing state.

If you have any more issues with this in RC2 let us know.

robertjacobs
2012-12-20, 09:21
Just to clarify - Control subclassing is now fixed in RC2. If so then all that is required is SET CLASSLIB TO and we should be good to run/test DO FORM with parent controls.

barrymavin
2012-12-20, 09:26
Correct.

gregoryw
2012-12-20, 12:06
Is there any training available for converting foxpro apps to lianja ?

barrymavin
2012-12-20, 19:18
After we release Lianja App Builder in january we will be organizing some training courses. There is also a whole new documentation wiki coming online soon.

K!k3
2013-06-29, 10:53
When ca I get a tutorial for the VFP - Lianja's migration; some videos and examples?
Where has a Spanish forum?

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago)

K!k3
2013-10-04, 14:54
I need re-compile my VFP project in Lianja; to my clients; without changes, to dedicate to program my aplication new version [totally] in Lianja.

With all novelty, Lianja provides.

I want re-design my application; but in the next version.

Please help me

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)

SpringBox
2014-01-08, 13:05
Hi Guys

I have successfully imported VFP 9.0 project & all files seem to be there in my new APP.

I appreciate that I can use & call my .prgs from new Lianja pages but how can I use / reuse my existing forms?

In one thread someone said just issue a DO command from the console - How? (have looked & read for ages before writing this)

Its been so long since I've been a newbie with this stuff

Thanks in advance

SpringBox

SpringBox
2014-01-08, 13:25
Tried to use an imported vfp form on a page but every time Lianja crashes - any thoughts? Can't work out how to use existing forms which is pretty vital.

Anybody had a go at this?

davefoss
2014-01-08, 15:03
Hi Guys
I have successfully imported VFP 9.0 project & all files seem to be there in my new APP.
I appreciate that I can use & call my .prgs from new Lianja pages but how can I use / reuse my existing forms?
In one thread someone said just issue a DO command from the console - How? (have looked & read for ages before writing this)
Its been so long since I've been a newbie with this stuff
Thanks in advance
SpringBox

Hi SpringBox,

For testing purposes you can select the Console Workspace and enter DO <program>, or DO FORM <.scp_file_name>.

Unfortunately you can not visually manipulate your existing VFP forms if that's what you are trying to do.

Hope this helps.

davefoss
2014-01-08, 15:06
Tried to use an imported vfp form on a page but every time Lianja crashes - any thoughts? Can't work out how to use existing forms which is pretty vital.

Anybody had a go at this?

We will be happy to take a look at this, please log a ticket (http://www.lianja.com/support/newticket). In the ticket please explain the exact steps to reproduce the behavior and attach all necessary files. Thanks!

SpringBox
2014-01-08, 16:39
Thanks for prompt reply.

Making some headway but still unable to anything much with forms. Found out how to run basic VFP .prgs in the console window but imported classes are an issue - I will try to solve that.

I am confused as to what I can do with imported VFP forms either in :

Page - VFP forms - produces a section on the page but its blank in DEV or Runtime
Section - Custom Visual FoxPro also produces a section but that's also blank in DEV or Runtime

What are these for? Can I use my forms at all - if so, how?

Thanks in advance

SpringBox

yvonne.milne
2014-01-09, 07:52
Hi SpringBox,

I would recommend running your forms using DO or DO FORM from the Console Workspace first. That way if any errors are reported, you can see what's happening (and as Dave says, submit a ticket if you need us to look into it). Once you are happy with the behaviour of a form run from the Console, trying loading it as a new page from the Form Tools -> Page -> VFP Forms -> *.scp.

The Form Tools -> Sections -> Custom -> Visual FoxPro allows you to code a Section. This is documented here: http://www.lianja.com/resources/blog/39-coding-tips/190-developing-lianja-custom-section-in-visual-FoxPro

Regards,

Yvonne

SpringBox
2014-01-11, 06:17
Hi Yvonne

That makes sense but to remove all ambiguity, are you saying the imported VFP forms are NOT available visually to either see or edit but only as code representation?

Assuming that to be true, when I import a VFP form into a page section (I can see all the code and it looks fine) and press "Run" button on top right, nothing happens - no form, just a blank page. What am I missing?

Thanks in advance

SpringBox

SpringBox
2014-01-11, 09:06
Hi Yvonne

See how spoilt (lazy) we VFP developers have become? The reason why the imported classes were not running was the order in which the separate classes within the class library had been imported. In VFP it doesn't matter but clearly, in sequential code - you can't reference something that doesn't yet exist !!

It is a pity that the imported forms cannot be represented visually in terms of controls - I'm sure it would be possible.

Getting there slowly...

SpringBox

ghandinader
2014-01-30, 04:14
hi SpringBox,
i'm facing problem when try to run a form from the console, it ask for baseform class which is a build in class in vfp so i can't import it.
any help??

yvonne.milne
2014-01-30, 04:37
Hi Ghandinader,

Add the definition to your form (before baseform is referenced):


define class baseform as form
// ... any properties/methods you want to set
enddefine

Regards,

Yvonne

ghandinader
2014-01-31, 04:40
thank you for your help Yvonne, but i have another question since i'm new to lianja so after importing VFP project and put the form in a section>custom>vfp and everything is ok the form run, the next step is how to put this app from the lianja app build into the web??
please can you give me a clear introduction because i didn't find that clear in the web.

Thank you in adnvance

barrymavin
2014-01-31, 04:49
You can't run VFP imported desktop form apps in the web client.

You can reuse your VFP knowledge, data, and business logic and change the UI to use standard pages, sections and gadgets.

If you want to run your desktop VFP application in a browser then you need to use the HTML5 guacamole Client / Linux server which provides RDP inside a browser. I only recommend that for LAN usage not WAN.

ghandinader
2014-01-31, 06:25
so i can't run the imported vfp project in app center if i deploy it to the lianja cloud server?

barrymavin
2014-01-31, 06:33
No. If you want apps that run in desktop, web and mobile you follow best practices.

The Lianja native mobile client will have the Lianja/VFP engine in it.

barrymavin
2014-02-01, 03:11
There is no "baseform" class in VFP. There is a "form" class but no "baseform" class.

snelsoft
2014-02-18, 06:25
Hello, I have the same problem, can't find why it doesn't work.
I tried to drag my forms with the mouse into an open App.
But I don't think I gonna use it. I imported some forms by program and Lianja made a mess of it.

yvonne.milne
2014-02-18, 07:01
Hi Snelsoft,

If you have a problem with the VFP Importers, please Submit a Ticket (http://www.lianja.com/support/newticket) with information on how to reproduce the problem and attach any files required so that it can be investigated.

Thanks,

Yvonne

elmanco
2014-03-26, 13:29
Unfortunately you can not visually manipulate your existing VFP forms if that's what you are trying to do.
Is there going to be any tool to do that in future versions?

PD: hi everyone. First post here!

barrymavin
2014-03-26, 21:14
There is no plan for that currently. Everything (well almost everything) we are working on is stated in the roadmap at:
www.lianja.com/roadmap

If there is something you need you can submit an enhancement request as a ticket and it will be looked at to see if it's something worth making generally available.

If you absolutely cannot live without it you can sponsor it's early development and inclusion in Lianja.
http://www.lianja.com/services/sponsored-features

HankFay
2014-03-26, 21:45
Hi elmanco,

I think you'll find yourself making native Lianja forms (Form or Canvas), the more time you spend with Lianja. It's taken a few months at least for most of us to change our mindset from the VFP way of doing things. It took me longer, but the excuse I have is I started quite a bit ago (before the forum existed). The reality is it always takes me a while to grok a new way, even if I know deep inside (where I know things before understanding them) it's the right way.

Hang in there, we're all learning.

And welcome,

Hank

elmanco
2014-03-27, 09:20
Thanks!
My name is Federico, btw.
It's no so easy for us to re-code all forms. We (the company i work for) are looking for a viable way to migrate a large (really large) VFP Project.
I'll dig around and come back with more questions.
Thanks again.

davefoss
2014-03-27, 10:04
it always takes me a while to grok a new way

Hank

Hank, you wouldn't happen to own a cat that walks through walls would you? ;-) Gotta love Heinlein!

HankFay
2014-03-27, 14:27
Hi Frederico,

we (my day job <s>) are also going to be converting a large app (650+ tables). The complicated stuff isn't in the interface (because with maybe 20 exceptions out of the 591+ forms), we don't put code in our forms. And while there will be small adjustments having to be made to code in the business methods, they will be for the most part small, and most of them will be able to be handled with search and replace (references to an oapp object, etc. -- which we will be getting rid of because of multiple reasons that add up to working better). For the most part, a junior-level developer will be able to recreate our forms, once the topography (what form corresponds to what page/section of what small functional app) is set out for her.

Everyone's business model and app model is individual to them, of course. In our case, we will have a huge TCO reduction when we can run our hosted customers as web (browser) clients. And our largest customers will likewise benefit.

enjoy,

Hank

j.nord
2014-04-09, 02:45
It did great you have all your code outside of the mask, but that is not the purpose of the conversion. We also have the code in the masks and wish us a conversion in which you have to rewrite the program.

HankFay
2014-04-09, 07:25
Hi J,

It is possible to import your forms into Lianja. Have you seen the guide to importing VFP files? http://www.lianja.com/documentation/documentation-index/307-importing-visual-FoxPro-files

I would also suggest you read the introduction for VFP developers, if you haven't already done so: http://www.lianja.com/community/lianja-for-vfp-developers

hth,

Hank

K!k3
2014-04-28, 11:18
Hi Frederico,

we (my day job <s>) are also going to be converting a large app (650+ tables). The complicated stuff isn't in the interface (because with maybe 20 exceptions out of the 591+ forms), we don't put code in our forms. And while there will be small adjustments having to be made to code in the business methods, they will be for the most part small, and most of them will be able to be handled with search and replace (references to an oapp object, etc. -- which we will be getting rid of because of multiple reasons that add up to working better). For the most part, a junior-level developer will be able to recreate our forms, once the topography (what form corresponds to what page/section of what small functional app) is set out for her.

Everyone's business model and app model is individual to them, of course. In our case, we will have a huge TCO reduction when we can run our hosted customers as web (browser) clients. And our largest customers will likewise benefit.

enjoy,

Hank

I'm having similar work; our app have also 400 free tables and also 6 databases, and many forms and reports.

I don't know create forms in Lianja (with control bar, minimize, etc), i'm a lot confused

How can use a "data source" in a canvas?

Thanks.

P.D.: Does exist any Spanish documentation about?

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

mclifford
2014-05-01, 12:22
We are using visual maxframe which has inherently 2 levels of classes, then we have our own classes and sub classes. How do we go about importing a project that has 4 levels of classes? Lianja insists they be ordered in a hierarchy order, but FoxPro does not.

lianjasupport
2014-05-01, 13:02
The first thing you do is import the individual vcx files.

Once they are imported they will exist in source code as vcp files.

you then need to arrange the SET CLASSLIB commands to load the class libraries in the correct order so the compiler knows about the classes when it is parsing.

Once you have got to that stage we will assist you from thereon.

mclifford
2014-05-01, 13:32
Do I need to set classlib for every vcp file, or is there a way to apply it to all of the files in the project?


The first thing you do is import the individual vcx files.

Once they are imported they will exist in source code as vcp files.

you then need to arrange the SET CLASSLIB commands to load the class libraries in the correct order so the compiler knows about the classes when it is parsing.

Once you have got to that stage we will assist you from thereon.

barrymavin
2014-05-01, 22:55
The importer will do that for you but you may have to change the order of them manually.

mclifford
2014-05-02, 11:05
OK. I still need to know where to do that.

yvonne.milne
2014-05-02, 12:21
Hi mclifford,

When the importer reads your scx files, it will pick up the classloc for the objects and add in a


set classlib to "name-of-classlib" additive

at the top of the scp source files it creates (your vcx files will be imported as vcp source files).

You can check these and reorder if necessary. Alternatively, if you start from a prg, you can put the set classlib ... additive commands in there.

Regards,

Yvonne

K!k3
2014-05-08, 19:51
How can I browse (to modify) a table.

Tanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

HankFay
2014-05-08, 20:28
From the console:

select mytable
browse

hth,

Hank

K!k3
2014-05-10, 11:50
From the console:

select mytable
browse

hth,

Hank


Thanks
Very Much

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

K!k3
2014-05-26, 18:08
Who knows how can I "call" another form (or page) inside one?
Like VFP is do form name

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

HankFay
2014-05-26, 18:43
Lianja.showdialog() or lianja.showdialogpanel() with a page saved in a page library will do the trick.

Hank


Who knows how can I "call" another form (or page) inside one?
Like VFP is do form name

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

K!k3
2014-05-28, 18:10
Well, but I want a example ;) for better comprension.

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

HankFay
2014-05-28, 21:09
There are many examples on the forum. Search on showdialog and showdialogpanel. I suggest saving the ones you find useful in a (free) Evernote notebook (I created a Stack for Lianja Forum information, and notebooks in the stack for different topics).

Hank


Well, but I want a example ;) for better comprension.

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

K!k3
2014-08-05, 11:50
How can set a .prg as main un the project?

Thanks

Victor Navarro
Barranquilla, COLOMBIA
3008102508
ICQ 279 364 380
Face: +573008102508 (http://www.facebook.com/victorenrique.navarrohoyos)
MSN: eres_un_vago@hotmail.com
Mail: eres_un_vago@yahoo.es (mailto:eres_un_vago@yahoo.es)
Whatsapp: +573008102508
Skype: eres_un_vago (skype:eres_un_vago?chat)
PIN: 7A3F5E60

HankFay
2014-08-05, 13:19
Does the application have a User Interface? If not, you can run the .dbo directly from the runtime (see the docs on that topic).

If it does have a UI, then you can use the delegates that fire on the way to presenting the User Interface, picking the delegate that makes the most sense for your prg.

hth,

Hank

mastb
2014-08-25, 12:26
Hank or Barry,

I have been away from Lianja for a while, and am now looking at it again. Any thoughts on the viability of importing a rather large Promatrix (V. 9.0) desktop multi-user application into Lianja? Am I better off starting from scratch, since importing would involve carrying all of the Promatrix built-in overhead?

Thanks,

Bill

HankFay
2014-08-25, 16:23
Hi Bill,

Besides the copyright/eula issue with porting the promatrix framework over, which I take very seriously, Lianja has different sets of strengths, and a different UI framework, so moving over as-a-whole doesn't make a lot of sense.

In our case, we made our business rules in classes that depend minimally on the promatrix framework. Moving them over will be quite easy. So it depends on how your app is constructed. I didn't see it coming at the time, just followed the path of least resistance (i.e., the very thought of debugging business code in forms made me nauseous).

If you used xCase2VPM, I have an alpha xCase2Lianja working, including generation of RI deletes (taking advantage of Lianja's ability to use fast table-based operations within the Lianja SQL Server). This is just a stepping-stone to having our own metadata dictionary (and UI for creationg entities and relationships, etc.) and creating/updating the DB from there (and also setting metadata within the UI using extensions). So if you were using that (great-if-I-do-say-so <s>) tool, you will have some relief in that area also.

It's still a project, not a simple conversion. But then again, you get what is essentially a new app that will be updated into the current world, vs. that of 10 years ago.

Hank

mastb
2014-08-26, 08:31
Hank,

Yes, the copyright/eula issue is not something I would violate - I just thought of importing the whole project as a starting point. I'm really just thinking in "macro" terms at the moment, not specifics. But I see what you mean - Lianja is built with different methodologies and is based on a more modern object model. Regrettably, the app was originally started in 1984, and still contains a lot of form-based business logic......

I'm thinking of writing code to grab metadata information from Promatrix (field caption, picture, etc.) to fill in some of the column attributes in the imported Lianja tables. Would your metadata dictionary (and xCase) be a better solution, long term?

Thanks for your thoughts, Hank

Regards,

Bill

HankFay
2014-08-28, 11:51
Hi Bill,

we have a VPM2xCase module also, although it's fairly primitive I believe it does handle captions, perhaps list defs.

xCase is a good solution for now. We are in the (long) process of creating is a UI in Lianja that will allow visual creation of tables and relationships with diagrams. With the app (ERD4Lianja) will come our enhanced metadata.

Either way an app of any complexity should (in our feeble minds) be planned and maintained in a Visual ERD designer. There are people who can keep it all in their heads: they shouldn't be wasting their time reading the forum. <s>. The business rule code is also triggered from within the data model (field triggers, which in VPM we have as cascading; and entity triggers). Part of the reason we want our own UI is the ability to push this code out to prgs in Lianja, keeping the prg name in the metadata, and directly editing from within the UI. xCase is a great tool with many more features, especially in defining various SQL backend databases that match your model. We are looking primarily at working with Lianja SQL, and with other backends only if driven to it by a (big) customer's needs. But the full range of capabilities we offer will be tied to Lianja: the tight integration is what makes all the metadata worth having.

W'e're doing this because we need these capabilities in our work. I think they would help efforts like yours quite a bit also.

FWIW: the new tools will be FOSS (shared in LianjaX), with consulting support in their use. The Red Hat model of "sell the sizzle, not the sausage." <s>

Hank

rboatright
2014-09-09, 23:15
Hank,

I know I'm reaching back 2 years to reply to a post, but it speaks to a problem I need to deal with.

We have a substantial promatrix application that we need to port to something new, and the latest releases of Lianja seem to have resolved the issues we needed to deal with.

However, (isn't there always a however) we have long exposed part of the Promatrix data manager to our clients to allow them to change field names, defaults, messages, tool tips, and to allow them to create and edit pick lists for fields.

In looking at Liajna, I don't -think- I see a way to expose that functionality. Ignore RI issues, that's comparatively minor for me, (which makes me odd) but reconstructing Promatrix's form_toolbar class pretty much from scratch seems like more than I want to pick up, which is why this app is still _in_ foxpro in 2014.

Heck, that's why we never moved to C# or Python or anything else. No framework I've ever used gave me what form_toolbar gave me.

Am I overlooking something?

HankFay
2014-09-10, 10:59
Hi,

somewhere in the roadmap is the ability to subclass the visual objects in Lianja. That is what's needed to get the full functionality you are seeking.

We (my consulting company, and the other company where I'm CTO during the daytime) are dealing with this by creating a metadata dictionary (currently to be stored in xml along with the database, to aid in updating; moved to cursors when needed -- Lianja is very good at this). This will be us builders (also easy to create in Lianja) to modify things like captions and tooltips -- as these are not dynamically supplied from the Lianja DD, but only supplied when creating a UI design surface. Given that Lianja is designed to scale to enterprise proportions, this makes some sense: there is horsepower used in all the dynamic stuff in ProMatrix. That said, for most, but perhaps not all, attributes in the UI design surfaces, macros {...} can be used to make those attributes dynamic (using a prg that goes and looks up the value from the accessory metadata, etc.).

Defaults are stored in the Lianja DD (actually in the table header, I believe, along with the other table and column constraints). These are all modifiable through code, so in theory they could be changed (assuming the table was used exclusively, which is also the case in Lianja for changing a field name).

Currently, I have an xCase2Lianja data schema converter in process (it works, is being extended to handle additional metadata). I might do a VPM2Lianja converter if a client needs it, or if there are suddenly a slew of VPM devs moving to Lianja. Our tools for Lianja will be FOSS, eventually making it to the LianjaX repository. Selling tools is not our core business, and we need the tools for our own work.

So: no easy solution for now, but most of what you need to get the dynamic data dictionary features are reachable. When visual objects are able to be subclassed, in whatever form (Lianja has additional options for dynamic modifying of methods, akin to interfaces), we will have the ability (which should be used wisely if targeting the enterprise) to make things all dynamic. Since we do target chiefly the enterprise, our work likely won't focus on that (again, unless a client needs it).

thanks,

Hank

rboatright
2014-09-10, 11:56
I'm presuming you ment that "There will be UI builders..." -- and of course, UI builders are available in lots of programming environments, .net, django, etc. The issue is, outside of Promatrix, non of those environments builders are dynamic.

I certainly know that the dynamic stuff imposes a performance hit, that there is horsepower used for it, but of course, in a system with only a few dozen tables, and assuming you've designed your views well so that no single form is hitting more than a couple of views, that hit is small.

I know that prgs and macros can go and look up the meta-data, and can reach in and change the attributes, but essentially, what you're saying is "Design a meta-data dictionary that handles the parts of the Promatrix system you need and impose a naming scheme on your forms to allow a prg that is fired on refresh to update from it." Or put another way, "yes, you can write the dynamic screen parts of promatrix in Liajna if you want to."

That's pretty much what I had determined. For the life of me, I fail to understand why the idea of meta-data-driven UI is so foreign to most developers. Oh well. Thanks for the reply.

As we look at it, Liajna looks to be our only rational choice going forward. I suppose I'm going to have to go back into the "Tools to build tools" business again.

Thanks

Rick



This will be us builders (also easy to create in Lianja) to modify things like captions and tooltips -- as these are not dynamically supplied from the Lianja DD, but only supplied when creating a UI design surface. Given that Lianja is designed to scale to enterprise proportions, this makes some sense: there is horsepower used in all the dynamic stuff in ProMatrix. That said, for most, but perhaps not all, attributes in the UI design surfaces, macros {...} can be used to make those attributes dynamic (using a prg that goes and looks up the value from the accessory metadata, etc.).

HankFay
2014-09-10, 20:37
Hi Rick,

I'm not sure a naming convention will be needed; Lianja is really all one big object tree, starting with the Lianja object. I would see climbing the tree of the activepage.activesection etc.

But yes, we are rebuilding tools as I mentioned. That's bad news in the sense of the work required. It's good news in that they will be able to grow with Lianja.

Hank

rboatright
2014-09-13, 16:22
Well, without the ability to subclass visuals objects I don't see how I can link the label for a field which the meta data for the associated field to get the caption, much less do things like arbitrary pick lists for text fields. Unless I use a naming convention. Now, if I had an "active label" class....

barrymavin
2014-09-13, 21:04
What exactly are you trying to achieve as your forum post does not describe this.

Subclassing a label? For what purpose? Lianja UI is all skinnable with CSS and picklists (data mapping) is a core feature.

explain what it is you are trying to achieve then we can guide you in the right direction.

rboatright
2014-09-14, 04:56
actually I did explain it in several of the previous posts but to try one more time the idea is to have dynamic forms.

In the programming environment we use, in the data dictionary for a table or a view, we can set the grid label, and the form label, and the input mask, and the default value, and the when clause and the tooltip and we can create a pick list for any field and ALL THESE THINGS CAN BE CHANGED in the final compiled program because the label object knows what field its the label for and retrieves its caption from the data dictionary and so on.

So, if a client wants to rename the field called supervisor to trainer, they can. Go to data manager, edit the label for the supervisor field to trainer, and go back to the form and by golly, it's changed.

The data manager can tell a field it should be audited, every change and edit tracked, or not. It can tell a field it must be unique. It can set permissions tracking so user login by login you either can or can not edit it. Or even see it.

All of this is dynamic at run time and doesn't require 're running builders.

But its all highly dependent on the ability to subclass visual objects, to create a textbox class that has the extra properties and methods to do those things, to create a grid object class that knows to get the column labels from the 'grid label' property in the meta data for the field specified in the data object of that column...

That's a small fraction of what Promatrix gives us, but it might give you a feel for why we're so reluctant to change.

Data dictionary driven forms, data dictionary driven security, auditing, activity tracking, error logging and management, dynamic meta data driven menus, etc etc etc.

I want Promatrix, in a modern 64 bit real language. Liajna would be perfect, I could recode PM except you don't support subclassing visual objects.

Which I admit, I don't understand. One of the true beauty of FoxPro is, you can subclass ANYTHING. You can add properties and methods, you can override methods, whatever.

In every current language ... ok I admit I don't know Haskell ... I run into limitations on that.

Honestly, sometimes I just throw up my hands and code in JavaScript.

rboatright
2014-09-14, 05:02
by the way Barry don't take that to suggest that I don't think that you've accomplished something amazing in Liana you have it's astonishing.

it's just that like every other programming environment I find things that are annoying especially things that are missing that I'm used to and being able to subclass anything is one of those things that I'm used to.

but don't take that to mean that I don't think that i don't think liajna's great. I do think so. This was whining.

barrymavin
2014-09-15, 02:35
I understand what you are saying but I must also point out that the basis behind Lianja is to build one App that can run on Desktop, Web and Mobile devices.

In fact security based permissions for the UI are built into Lianja and in the next release (as stated on the roadmap) we have implemented "Dynamic Roles and Permissions".

The ability to subclass the UI elements; page, section, and field and inherit core functionality, attributes and delegates is in the roadmap for v2.


Ability to use custom UI classes in form and canvas sections.

Additionally, in Lianja each table has a data dictionary with a variety of attributes that can be "Inherited" when the App is loaded. Not all of them are exposed in the UI but you can find them looking at the ALTER TABLE documentation.

pauln
2014-09-16, 01:21
Great discussion Gents!
Being in depth with Promatrix, VFP and the minority here in Oz - its great to see common ground.

Barry really looking forward to getting into Lianja soon and making our mark down under. V2 is probably when we get serious as the Visual Designer and the ability to import Reports will assist greatly.
(PS: Hi Hank - loved your work on xcaseToVPM from a licensed user)

rboatright
2014-09-25, 18:43
Barry, thanks. As I said, don't think I'm being ungrateful. Like the others, I suspect that until the ability to subclass the UI elements, and to use custom UI classes in a form happens, we're going to be very frustrated puppies.

I understand about the Lianja data dictionary, and I've spent serious time looking at mapping the ProMatrix DD onto the Lianja DD. The fit is "difficult."

Without the ability to subclass UI elements, or to use custom UI elements, in order to get the dynamic response we're looking for, we have to modify -each- field, -each- button, -each- label to respond to the changes in the DD the way we want them to, rather than just saying "This is a "RicksApp" label that does the following things in response to a change in the data dictionary." The beauty of subclassing, of course, is that you don't have to -do- that any more.

We've considered writing a "form helper" that gets called from the init and refresh method of the form and scans the form for "stuff we want to happen." That way we would only have to add one custom method and a couple of calls to every form. Clearly, that's better, but it's semi-complex to implement, and would be wasted work once V2 is available.

So, we're continuing to experiment, and waiting. I've been watching and playing with Lianja since long before V1, and have been super happy with what you've accomplished. This is -so- close to my dream environment I'm just frustrated about the inability to quite lever myself up over the edge and to drop VFP and it's 32 bit database into history.

rboatright
2014-09-25, 18:44
Paul, it's good to know that we're not the last cowboys still punching away at ProMatrix. :-)

My question has long been, "why don't other people develop this way?" Oh well.

pauln
2014-09-26, 09:41
Hey Rick - Wow, great question and requires some self sole searching just to contemplate an answer...

Without going into too much detail and boring the rest much has changed over the last 32 years when I started working with micro's. But to the point I spent the entire day assisting a client with Server & IT issues asking their IT consultants why Exchange was chewing 97% of physical memory; why the Server was so locked down none of the VFP screen would load; why the hell I was not in my holiday apartment in Mandurah drinking a beer?

The "gap" now is too wide to justify and the risk of becoming stale too close. So as you said "...drop VFP and it's 32 bit database into history" So we soon will entrust our futures with Barry and his team...

HankFay
2014-09-26, 10:46
Hi Paul (and Rick),

Yes to all of that.

And I would add "to Barry and his team" an "and to us", with "us" being not just ProSysPlus, but all of us who know metadata-driven software development. Especially users of xCase2VPM. :) We do know the benefits of metadata-driven development in a way the vast majority of software developers do not. So it's not just up to Barry, but also to us. Lianja has the hooks, even without subclassing (which is of questionable value when thinking of Javascript apps): we need to think out way through the possibilities and then put the result into libraries and extensions that do the needed jobs.

We (ProSysPlus) will be making our tools available to the community on LianjaX. Having others join us in that effort will make the effort go faster.

Are you interested?

If so, I would suggest we meet up on Skype or Zoom (I have a meeting we can use) to create a plan of action.

Hank

rboatright
2014-09-26, 16:34
I certainly am interested.

I expect that we will be able to begin actually working on tool building around the first of the year. We're in the middle of a major software release just now, but in a couple of months, that will be mostly past.

In the mean time, I certainly think that a consultative meeting for people who are familiar with meta-data-driven software development to develop a road-map for bringing mddsd into the Lianja community. '

I suspect that we ought to move this conversation to a new thread, in order to be "more visible" to the Lianja forum community.

If you have a half-hour to spare, I would love to chat with you about your thoughts on the general subject whenever you might be available.

contact me via skype at rick.boatright or via email at boatright at tbcsoftware dot com