locked
Sync, Reports, Fonts etc.. RRS feed

  • Question

  • Hi to everybody, just to know I`m realy new here and I`m working with LS just few weeks, so please make me answers on next questions like you`re explaining something to your grandpa :)

    - Is it possible, somehow (and how?), to synchronize two lightswitch app databases one on web another one on desktop local client? (Ofcourse they have same tables and columns)

    - Is there ANY way for creating reports in LightSwitch? Ofcourse, I`m not talking about DevExpress, Office integration and SQL Reports. I need some CHEAP and good solution for my client. Why? They are not willing to pay for Office license, I can`t afford 1.800$ for DevExpress, and I found not really easy creating reports with SQL reports.

    - When I`m trying to deploy(publish) my application, HOW can I make it to work on ANY dekstop PC where is installed? Do I have to make different setup everytime when I`m instaling app to clients or?

    - How to change letter fonts? I want all letter in app to be bigger for 20%, because when it`s showing on large screen it`s not that much easy for everyone to see what`s writen.

    -How to make both fields on the same screen editable but they are from different tables?

    There will be more questions, believe me, for now I urgently need answers on these two.

    THank you in advance,

    Nikola




    • Edited by Nidzaaaa Wednesday, February 27, 2013 1:04 PM title and paragraph
    Wednesday, February 27, 2013 9:03 AM

All replies

  • alo Nidzo!

    - i guess it's possible to write code to synchronize two databases, but it really depends on structure of your database (and project), if it's already there (external data source), you can import two "same" datasources (and choose to work with just one of them, other will serve just to synchronizing purpose), when you deploy you can change connection strings in config file (you'll have them 2) for one to point on local database, and other to point on web for synchronization.. if you work with intrinsic datasource, then i guess it's doable across wcf ria service, but there could be more of work to do.. 

    - not sure for v12, but v11 of devexpress reports for lightswitch price was 100$.. maybe other way is to use silverlight printing capabilities and create your own printing forms, but amount of work needed for that extends 100$ price for xtrareports (at least for me, maybe for you is piece of cake).. 

    - when you deploy 2 tier app, you can choose which prerequisites will be prepared/installed with your app..

    - in VS gallery you have free extensions which can do what you need (ie pixata) for some screen controls, but if you want to change overall look of your app, you can create theme extension with extensibility toolkit, it's not that hard, but can be lengthy process.. 

    - not sure if i understand last correctly, but you can add new data item (query) to screen and work with them both, for example you create editable grid screen with customers query, then you can change your screen layout to tabs, and put customers grid in first tab, then add another tab, after that add another data item (query) to screen like countries and put it in second tab, so now you have screen with two tables, each one is editable, and when you save changes, it's saved for both tables..

    hth..

    Kivito


    Nobody expects the Spanish Inquisition! (M.P.F.C.)

    Wednesday, February 27, 2013 6:09 PM
  • Hi Kivito,

    Thank you for answering me.

    I am using intrinsic datasource, now I see that`s not that much good solution. Why? I still don`t know that :) I see there is no a lot of tutorials on web for intrinsic datasources, since almost everyone is using external datasource. ANd that`s realy bad for me.

    I think I`ll give a shot to DevXpress anyway, since I see there is no better solution for creating reports for my business application.

    When I`m trying to deply my 2-tier application, there is setup for connection string, but what should I use as prerequisites so I make my connection string universal for everyone, so when anybody want to install my app it will be working anyway? Do I just have to add ".\SQLEXPRESS" and after that mark for installation SQL server also (on the end) and after that my application will automatically install whatever is needed for working properly? Sorry if I wrote this confusing :)

    Is it possible to change ONLY fonts of my application without using any second-part extension? Something like ex. I open some config file, find line where it says "APP FONT=8" and change it to value 10 or any other?

    Thursday, February 28, 2013 9:44 AM
  • hi!

    - i believe that it is much easier to develop application with intrinsic datasource, then lightswitch take care of database, relations, etc.. with external datasource you need knowledge of setting up database by yourself (or someone gives you ready to use database) with relations, triggers, etc.. but you have specific problem (sychronization of databases), btw i've read one of Paul van Bladel's posts about microsoft sync framework which can help you to achive this synchronization, although i  didn't play with that.. check this link(s) for more: http://blog.pragmaswitch.com/?author=1 ..

    - when you install sqlexpress on new pc, default name for instance is always ".\sqlexpress", so i guess this will repeat on every new pc for installation..

    - im not sure about fonts config, as im aware -  no, but never say "never"..

    hth..

    Kivito


    Nobody expects the Spanish Inquisition! (M.P.F.C.)

    Thursday, February 28, 2013 1:29 PM
  • I swore off the intristic database when it just decided to delete my data when I made a data change it thought it needed the data gone.  I would rather make all changes myself through SQL Server's tools.

    But, I'm a heavy SQL Server user, so I want stuff in SQL.  I'm thinking to write a post for extended review to see what others are doing, but for my internal development, this is how I prefer to set up my apps so I have MAXIMUM flexibility with the data.

    1. Create databases through SQL.  I use the interactive tools, so it is all visual, just as easy as inside LightSwitch.  The biggest differences is you have to handle your identity and foreign keys yourself... no big deal.
    2. Create the relations for the tables using the Database Diagrams.  Therefore all relations inside a single database are represented on the server.
    3. Attach to the database using the external database.  The relations on the server are represented in LightSwitch without any further work.

    Because of using this method, I do this so that I can change what database and database server (that have the exact same structure) within a minute.


    <<-- Did I help you? Please oh please mark my comment as helpful: I finally have a few points (thanks Yann!) (BIG GRIN!) (JoeB)

    Thursday, February 28, 2013 3:25 PM
  • As for Reporting, here is what I have done, and it doesn't COST anything:  Use SQL Server 2012's Report Builder 3 with SQL Server Express:

    Here are the steps I've used:

    1. While installing SQL Server, make sure you include the Reporting Services
    2. Install SQL Server 2012 Report Builder
    3. If you can write a report directly from the tables (letting Report Builder do all filters and parameters) or use the Work Table Method.
    4. If you want to use the work table, Your reporting prcedures update a work table such (I've talked about this type of processing in this post: Here )
    5. Using the work table, create your report using the Report Builder.
    6. Post the link in lightswitch (using the Pixata Web Link) that will reference the report in the format like this: http:// servicername/ ReportServer?/ ReportPath/ REportName&parametername=99 (note, I added spaces so it won't make a link)  (note the 99 is whatever your parameter default... I pass the report run ID so multiple users can have different versions of the report in the same work table)

    I'm sure the tools you can buy are good, but for me, SQL Server has everything I need, and once set up, it is a piece of CAKE!

    GOOD LUCK!


    <<-- Did I help you? Please oh please mark my comment as helpful: I finally have a few points (thanks Yann!) (BIG GRIN!) (JoeB)

    • Proposed as answer by JoeB_LS103 Monday, March 25, 2013 7:10 PM
    Thursday, February 28, 2013 3:45 PM
  • JoeB thank you for good answers.

    Can you please provide me some tutorials for making reports thrue SQL Server?
    Btw, which version of SQL should I have to be able to use Reports?

    I have installed 2008 R2 and 2012, but nowhere I see reports

    Friday, March 1, 2013 11:17 AM
  • Sorry I missed your reply.

    Did you find out how to do this?

    Here is the reporting services setup info for 2008 r2:

    http://msdn.microsoft.com/en-us/library/bb522676(v=sql.105).aspx

    I used 2012 for my work, but 2008 r2 should work fine.

    I must admit that report services are a little confusing, so have google in hand, and have some fun working through all the problems.


    Would someone please turn on the LIGHT?

    Monday, March 25, 2013 7:10 PM