locked
New at DD RRS feed

  • Question

  • User248012991 posted

    Hi I'm Karla. I am a freshman at Data Dynamics. I've only seen a few videos and I use the most professional tool to develop programs

    Not English so I use the Google translation

    Working in a small school and I did with the database as shown in the videos and the thing seems to work well so far

    I want to know how to grab the data that is on my screen in a FormView. I mean grip I have in my power every typed data on the screen in text fields, date, Boolean and combos

    All I want to grab before inserting to database

    You can do that?

    Tuesday, August 9, 2011 11:03 AM

All replies

  • User248012991 posted

    Maybe you need to explain a bit what I will do:

    For one example of my request I convert a numeric field in letters

    That is for the system of checks should be saved as transactions both in numbers and in letters

    If I have an independent variable with the value in the way I typed in the transformation could make a fairly easy because I already do with other languages.

    So these routines and in another language but do not know how to do it in dynamic data

    Tuesday, August 9, 2011 6:52 PM
  • User-330204900 posted

    Hi Karla, if you add an event handler to the DataSource ont heInserting event you will have a collection of value you can look at e.Values. However it depends on what you want to do with the values as to whether this is the best place to do it.

    P.S. do have a look at VisualStudio LightSwitch 2011 it's a much more rapid development tool for small business apps.

    Wednesday, August 10, 2011 7:45 AM
  • User1043796333 posted

     I'd like to know this answer too

    Wednesday, August 10, 2011 10:25 AM
  • User248012991 posted

    Dear Mr. Sjnaughton, present: I could not find DataSource ont heInsertingesa but if I'm right you're working with German language version and seems to refer to the insert, yes? . I'll try there

    The first thing I do is grab information from a numeric field that is already there typed on the screen within the form and we already have a little program that makes the number of letters and so saved. It is because the audit have requested this check because before someone stole money in checks that do not have this level of security.

    In other programs is easy because you know the name of the field and know where to go to fetch the dynamic data value but it is not known or not so obvious

    Know if the level of question is too elementary for the level of you but we could use a little help bien.Voy to see the program you indicated to us later.

    Sorry one last question. Note that I do not find what you say. Where is he? As it located?

    Wednesday, August 10, 2011 10:35 AM
  • User1043796333 posted

    I wasn't writing here anymore in this forum even though I read it all the time

    I decided to partially quit by abandonment on this and try to help you:

    In:

            protected void FormView1_DataBound(object sender, EventArgs e)
            {
                var FormView1DataBound = GetItemObject<System.Data.Objects.DataClasses.EntityObject>(FormView1.DataItem);
            }

    Right there you have all the values you need but I don't know how to go inside the variable to do a loop and find individual values because the name of the entity that I need to disclose the data matrix can be seen while debugging time with

    ((System.Web.UI.WebControls.EntityDataSourceWrapper)(FormView1.DataItem)).WrappedEntity;

    But there is no implementation of EntityDataSourceWrapper because of its level of acces (it's hidden)

    ((MyApp.DataModel.products)(FormView1DataBound))

    That's because MyApp.DataModel.products is not a string but something that can be built through reflection only but I don't understand how to do that yet

    Maybe someone here can help you with that

    Wednesday, August 10, 2011 11:32 AM
  • User1043796333 posted

    To sjnaughton

    I have to tell you that this is not as simple as it looks

    Dynamic Data does a lot of trips around many different methods of thr FormView many times. I'd say that maybe too many times so you don't know where to stop and catch the right value or matrix with data coming from the form

    Maybe you can add this topic in your coming book. Hopefuly it will also be released this month the other book on Dynamic Data by Oleg Sych

    Wednesday, August 10, 2011 11:47 AM
  • User-330204900 posted

    Hi Topolov, I understand that but I do it that way Undecided.

    Have you looked at Visual Studio LightSwitch 2011 just recently released? It may be what you want, I will be heavily inveting in it over the next few weeks as I have several projects in September that it will suit.

    See my post here Visual Studio LightSwitch 2011 Arrives (Yes, I know it arrived a while ago!) it's a lot like DD but the third party support is 100% in comparison to the thirpart support of DD. Don't get me wrong I will still be supporting DD and producing addons to it but for really rapid LOB apps for most of my clients I think I will go LightSwitch it is awsome.

    As you can see from my article I build myself a simple accounts app for my own use, I have completed it an less than three days, that woudl have taken me at least a week with DD if not longer.

    Wednesday, August 10, 2011 12:22 PM
  • User1043796333 posted

    So you mean switch from Dynamic Data to to Visual Studio LightSwitch 2011 ? What about MVC? IS Visual Studio LightSwitch 2011 going to be what Dynamic Data once was and be overriden later by something new incoming?

    On the other hand: is there a way of making a loop on

    var MyFormData = EntityDataSourceExtension.GetItemObject<System.Data.Objects.DataClasses.EntityObject>(FormView1.DataItem);
    Diego Vega's piece of code?
     
    In my case all I need to do is gather the values contained inside the variable MyFormData? 
    How do I loop it? Do you know? 
    Is somehow impossible to do that? Where can I leran about this?
    Wednesday, August 10, 2011 12:42 PM
  • User1043796333 posted

    So you book on Dynamic Data will be delivered or it is on hold?

    Wednesday, August 10, 2011 12:45 PM
  • User-330204900 posted

    Still waiting for a deal from O'Reilly I'll chase them when I'm not so busy :)

    Wednesday, August 10, 2011 1:47 PM
  • User1043796333 posted

    Any idea on this too?

    On the other hand: is there a way of making a loop on

    var MyFormData = EntityDataSourceExtension.GetItemObject<System.Data.Objects.DataClasses.EntityObject>(FormView1.DataItem);
    Diego Vega's piece of code?
     
    In my case all I need to do is gather the values contained inside the variable MyFormData? 
    How do I loop it? Do you know? 
    Is somehow impossible to do that? Where can I leran about this?

    Wednesday, August 10, 2011 1:55 PM