Search Results

Search found 11857 results on 475 pages for 'navigation properties'.

Page 9/475 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Schema to support dynamic properties

    - by Johan Fredrik Varen
    Hi people. I'm working on an editor that enables its users to create "object" definitions in real-time. A definition can contain zero or more properties. A property has a name a type. Once a definition is created, a user can create an object of that definition and set the property values of that object. So by the click of a mouse-button, the user should ie. be able to create a new definition called "Bicycle", and add the property "Size" of type "Numeric". Then another property called "Name" of type "Text", and then another property called "Price" of type "Numeric". Once that is done, the user should be able to create a couple of "Bicycle" objects and fill in the "Name" and "Price" property values of each bike. Now, I've seen this feature in several software products, so it must be a well-known concept. My problem started when I sat down and tried to come up with a DB schema to support this data structure, because I want the property values to be stored using the appropriate column types. Ie. a numeric property value is stored as, say, an INT in the database, and a textual property value is stored as VARCHAR. First, I need a table that will hold all my object definitions: Table obj_defs id | name | ---------------- 1 | "Bicycle" | 2 | "Book" | Then I need a table for holding what sort of properties each object definition should have: Table prop_defs id | obj_def_id | name | type | ------------------------------------ 1 | 1 | "Size" | ? | 2 | 1 | "Name" | ? | 3 | 1 | "Price" | ? | 4 | 2 | "Title" | ? | 5 | 2 | "Author" | ? | 6 | 2 | "ISBN" | ? | I would also need a table that holds each object: Table objects id | created | updated | ------------------------------ 1 | 2011-05-14 | 2011-06-15 | 2 | 2011-05-14 | 2011-06-15 | 3 | 2011-05-14 | 2011-06-15 | Finally, I need a table that will hold the actual property values of each object, and one solution is for this table to have one column for each possible value type, such as this: Table prop_vals id | prop_def_id | object_id | numeric | textual | boolean | ------------------------------------------------------------ 1 | 1 | 1 | 27 | | | 2 | 2 | 1 | | "Trek" | | 3 | 3 | 1 | 1249 | | | 4 | 1 | 2 | 26 | | | 5 | 2 | 2 | | "GT" | | 6 | 3 | 2 | 159 | | | 7 | 4 | 3 | | "It" | | 8 | 5 | 3 | | "King" | | 9 | 6 | 4 | 9 | | | If I implemented this schema, what would the "type" column of the prop_defs table hold? Integers that each map to a column name, varchars that simply hold the column name? Any other possibilities? Would a stored procedure help me out here in some way? And what would the SQL for fetching the "name" property of object 2 look like?

    Read the article

  • Why do so many wpf controls implement CLR properties instead of dependency properties ?

    - by msfanboy
    Hello, is it because the controls programmers are lazy, too hard to implement or not knowledgeable? Wether they are custom controls from 3rd party vendors or Microsoft itself, very much controls have often clr properties instead of DP. Result is I can not bind to them and is wpf not all about binding? :/ My next side question would be, why do so many wpf controls offer visual parts but they are not member of the visual tree ? see wpf datagrid columns, headers... What do you think?

    Read the article

  • Creating Class Properties in Visual Studio

    - by pm_2
    Using the standard VS IDE, is there a fast way to create class properties that are linked to the local variables? The class diagram seems to provide something, but it basically just created a property stub. Is there something better / easier out there ?

    Read the article

  • Silverlight 4: Binding to a calculation of control properties

    - by Rich.Carpenter
    What I would like to do is pretty simple. Given textboxes for ItemPrice, Tax and Total, I need the text value for Total to be bound to ItemPrice + Tax and the Tax value to display ItemPrice * taxRate. Could someone offer a brief explanation as to how this would be accomplished or point me to an appropriate example? I see property binding examples all over the place, but none that show binding to a calculation of the properties of two controls.

    Read the article

  • Adding format to properties

    - by chris
    I have an object with a couple of DateTime properties: public DateTime Start_Date { get; set; } public DateTime? End_Date { get; set; } I would like to set a format for each of these, along the lines of Start_Date.ToString("M/d/yyyy hh:mm tt") Do I have to code the get, or is there an elegant way to do this?

    Read the article

  • Define a default .properties file in JAVA

    - by bnabilos
    Hello, I have 2 .properties files in my java project and I want to define one of them as default file to be used when the language of the operating system is different from the 2 languages already defined. Can you tell me please what should I add to my code to make that possible? Thank you

    Read the article

  • What are common patterns for handling possible pluralization in message properties?

    - by C. Ross
    Obviously users like to see text properly pluralized, and pluralization schemes vary in the various written languages one may encounter. When internationalizing an app, what pattern(s) are useful for handling messages with possible pluralization? What about messages with multiple possible pluralization? For example: "N review(s):" One pattern would be reviews.title.singular="{0} review:" reviews.title.singular="{0} reviews:" And this may not support all languages. Or a more complicated case: "Found M question(s) with N comment(s)." This would be difficult to support in English?

    Read the article

  • The Properties dialog box not working for any Start Menu Program Lubuntu 14.04

    - by user236378
    When Lubuntu 14.04 first came out, the Properties dialog was present for all Start Menu Programs but did not work when right-clicked on as nothing happened and no other box popped up the the Start Menu Program information, such as the executable info, etc. Then the issue was fixed. Now the issue has returned when I upgraded to Lubuntu 14.04.1. Is there any way to retrieve the Properties info pop-up box via a configuration file? Does the issue have to do with a faulty LXShortcut? I noticed when I uninstalled the LXShortcut the Properties tab disappeared. When I re-installed the Properties tab returned however once again when you right-click on the Properties tab nothing happens. Any assistance would be greatly appreciated. Thank you.

    Read the article

  • Who should control navigation in an MVVM application?

    - by SonOfPirate
    Example #1: I have a view displayed in my MVVM application (let's use Silverlight for the purposes of the discussion) and I click on a button that should take me to a new page. Example #2: That same view has another button that, when clicked, should open up a details view in a child window (dialog). We know that there will be Command objects exposed by our ViewModel bound to the buttons with methods that respond to the user's click. But, what then? How do we complete the action? Even if we use a so-called NavigationService, what are we telling it? To be more specific, in a traditional View-first model (like URL-based navigation schemes such as on the web or the SL built-in navigation framework) the Command objects would have to know what View to display next. That seems to cross the line when it comes to the separation of concerns promoted by the pattern. On the other hand, if the button wasn't wired to a Command object and behaved like a hyperlink, the navigation rules could be defined in the markup. But do we want the Views to control application flow and isn't navigation just another type of business logic? (I can say yes in some cases and no in others.) To me, the utopian implementation of the MVVM pattern (and I've heard others profess this) would be to have the ViewModel wired in such a way that the application can run headless (i.e. no Views). This provides the most surface area for code-based testing and makes the Views a true skin on the application. And my ViewModel shouldn't care if it displayed in the main window, a floating panel or a child window, should it? According to this apprach, it is up to some other mechanism at runtime to 'bind' what View should be displayed for each ViewModel. But what if we want to share a View with multiple ViewModels or vice versa? So given the need to manage the View-ViewModel relationship so we know what to display when along with the need to navigate between views, including displaying child windows / dialogs, how do we truly accomplish this in the MVVM pattern?

    Read the article

  • Marmalade SDK views navigation concepts

    - by Mina Samy
    I want to develop a simple multi-Activity Android game using Marmalade SDK. I looked at the SDK samples and found that most of them are a single view (Android Activity) apps. The Navigation model in Android is a stack-like model where views are pushed and popped. I can't find whether Marmalade has a similar model or it uses a different approach. would you please explain this to me and provide tutorials and samples to navigation in Marmalade if possible ? Thanks

    Read the article

  • Webpage Construction For SEO - Navigation

    Few things are more frustrating then going to a new page you're interested in and finding out it has horrible Navigation. I mean the kind of navigation that would make Cheech and Chong look like they knew where they were going. A back button that doesn't work, dead homepage link, dead end pages..........you know, you been to 'em, and you never go back to them either.

    Read the article

  • Page Navigation and Passing, Sharing and Retaining Data in Windows Phone 7

    Page navigation would seem to be an advanced Silverlight programming topic, and a topic that applies only to Silverlight programming rather than XNA programming. However, there are issues involved with navigation that are related to the very important topic of tombstoning, which is what happens to your Windows Phone 7 application when the user navigates to another application through the phone’s Start screen.

    Read the article

  • Fix folder scrolling problem in navigation pane of Explorer

    - by Marko Apfel
    Since my first steps with Win7 I hate the behavior of Explorer to scroll down the current expanded folder in the navigation pane. Today I found a solution in this thread: Bug: Windows Explorer expands folders inappropriately, jumping the folder you expand to the bottom of the navigation pane Download and install Classic Shell Activate the classic explorer bar and choose options Verify that “Fix folder scrolling” is checked Verify fixed behavior If necessary deinstall Classic Shell – the fix is persisted

    Read the article

  • WPF: disable inheritance of properties

    - by Maximilian Csuk
    Hi! I would like to use a TabControl as the main navigation in the application I am working on. So I would like to make the font in the headers of the TabItems bigger and also give it another background-color. However, I do not want this to be inherited. For example, if I use this code: <TabControl FontSize="18pt"> <TabItem Header="Tab 1"> <Button>Button 1</Button> </TabItem> </TabControl> The font in the button is also 18pt big. I know that this is normal dependency property behaviour because the property is inherited, but that's not what I want in this case. I would like to change the TabItems without changing anything in the children. Isn't that possible? Because re-setting all children to default values is a PITA. Thanks for your time.

    Read the article

  • Spring: PropertyPlaceHolderConfigurer to set values for non-string/integer properties

    - by babyangel86
    Hi, All the examples I have seen where the PropertyPlaceHolderConfigurer is used seem to be setting simple values like Strings and ints. How do you use the PPC to set the values of classes. E.g. If i had a class signature Source(String name, DistributionSample batch, DistributionSample delay) How would I go about setting the batch and delay properties. There is also a small catch. DistributionSample is an abstract class. On the bright side, The class that is using the propertyPlaceHolder knows the beanName of the "Solid" class that needs to be instantiated. Any help would be much appreciated.

    Read the article

  • Overloading properties in C#

    - by end-user
    Ok, I know that property overloading is not supported in C# - most of the references explain it by citing the single-method-different-returntype problem. However, what about setters? I'd like to directly assign a value as either a string or object, but only return as a string. Like this: public string FieldIdList { get { return fieldIdList.ToString(); } set { fieldIdList = new FieldIdList(value); } } public FieldIdList FieldIdList { set { fieldIdList = value; } } private FieldIdList fieldIdList; Why wouldn't this be allowed? I've also seen that "properties" simply create getter/setter functions on compile. Would it be possible to create my own? Something like: public void set_FieldIdList(FieldIdList value) { fieldIdList = value; } That would do the same thing. Thoughts?

    Read the article

  • Visual studio does not gray out properties with a ReadOnlyAttribute(true)

    - by Fire-Dragon-DoL
    I know it's stupid but visual studio (2010) doesn't gray out my properties tagged with ReadOnlyAttribute, I can't edit their values (if I try to do it, simply return to the previous value), but they aren't grayed out, I think it's really boring this when using the editor Is there an option or an attribute that I'm forgetting? Thanks for any help Example 1: /// <summary> /// Inform if the LcdDisplay has been already initiated /// </summary> [Description("Inform if the LcdDisplay has been already initiated")] [DefaultValue(false)] [ReadOnly(true)] public bool Initialized { get; private set; } Initialized is not grayed out

    Read the article

  • WCF Service and Properties

    - by Karnalta
    Hi all, Here is my question, I have a solution with 4 projects in it for a WCF Service : DLL Library : Service Interface. DLL Library : Service Code. Form Application : Service hosting application. Form Application : Service client application. I'd like to have certain properties of the service accessible for the hosting application but not for the client one. If I declare a property in the client interface they will both have access to it. In fact, my service manage user identity login and keep a list of all user currently logged in. I'd like to be able to show this list in the Hosting application, like a debugging tool. But I don't want the service client to be able to access to this list. How can I do ? Thank in advance.

    Read the article

  • XAML, binding Width and Height properties to the same properties of other control

    - by JAG
    I'm trying to create a reflection effect and it's working great except that I have to hard-code some values. This is my XAML: <Grid> <Grid.RowDefinitions> <RowDefinition Height="60"/> <RowDefinition /> <RowDefinition Height="80"/> </Grid.RowDefinitions> <StackPanel Grid.Row="1" VerticalAlignment="Center"> <UserControl x:Name="CurrentPresenter" /> <Border Width="500" Height="200" > <Border.Background> <VisualBrush Visual="{Binding ElementName=CurrentPresenter}" > <VisualBrush.Transform> <TransformGroup> <ScaleTransform ScaleX="1" ScaleY="-1" CenterX="500" CenterY="99" /> </TransformGroup> </VisualBrush.Transform> </VisualBrush> </Border.Background> <Border.OpacityMask> <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.6"> <GradientStop Offset="-0.6" Color="Black"></GradientStop> <GradientStop Offset="0.6" Color="Transparent"></GradientStop> </LinearGradientBrush> </Border.OpacityMask> </Border> </StackPanel> </Grid> I've tried to replace Border's Width="500" and Height="200" by Width="{Binding ElementName=CurrentPresenter, Path=Width}" and Height="{Binding ElementName=CurrentPresenter, Path=Height}" but it doesn't seem to work. Wha's wrong with this code? UPDATE: If I set Width and Height here: <UserControl x:Name="CurrentPresenter" Height="200" Width="500" /> It works as expected. However it doesn't work if I set those values in the UserControl XAML. Any ideas?

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >