ScottinTexas's Profile User Rating: -----

Reputation: 0 Apprentice
Group:
Active Members
Active Posts:
60 (0.06 per day)
Joined:
13-March 12
Profile Views:
1,891
Last Active:
User is offline Jan 22 2015 06:46 PM
Currently:
Offline

Previous Fields

Country:
Who Cares
OS Preference:
Who Cares
Favorite Browser:
FireFox
Favorite Processor:
Who Cares
Favorite Gaming Platform:
Who Cares
Your Car:
Ford
Dream Kudos:
0
Icon   ScottinTexas has not set their status

Posts I've Made

  1. In Topic: Title Text For ComboBox and TextBoxes

    Posted 22 Jan 2015

    View PosttlhIn`toq, on 22 January 2015 - 01:51 PM, said:

    If you're coding WPF then you should have WPF Extended Toolkit installed. If not, get it.

    Then use the WatermarkTextBox.

    Don't use textboxes for dates. use DateTimePicker. The right tool for the right job. Just like you don't use Textboxes for numeric input: You use an IntegerUpDown, or DecimalUpDown control


    Thanks! I didn't know there was a date picker control. Or, for that matter, the DecimalUpDown control. None of the books that I have or the web sites I have visited mentioned those two. To be fair to the authors I guess it is impossible to mention everything. But it seems that a DatePicker would be one you would include in your text. I will spend the rest of tonight just going through the controls to see what's there. AFTER I install the extended tool kit.

    Thanks again. I'll redo my view and see how things go.
  2. In Topic: Title Text For ComboBox and TextBoxes

    Posted 22 Jan 2015

    Sorry. It's for WPF.
  3. In Topic: A Couple More Layout Questions

    Posted 22 Jan 2015

    No I wasn't thinking it would shrink to fit. I wanted the control to grow to fit. Which I have accomplished. Earlier yesterday when I added the Horizontal and vertical alignment values to the control, I didn't see any result. Doing that today it worked as intended. I still have some layout issues, but they are getting dealt with one at a time until it all looks good.

    I thank you both for your help.
  4. In Topic: A Couple More Layout Questions

    Posted 21 Jan 2015

    View PosttlhIn`toq, on 21 January 2015 - 02:11 PM, said:

    Have you tried placing the UserControl inside a ScrollViewer?


    No I haven't tried that. But it is all there. If you maximize the window the bottom of the "form" shows up. Just not fitting the entire space as desired. I don't suppose I (the user) would ever make the view smaller and cut off part of the control. But I guess there is an off chance that someone else may see the app and want a copy. So I guess I better plan on Bombproof rather than just working. I just don't know why all the crap I have read is not working as written. The title to this section in this book says "Rows and columns can resize to match the page size." Then it goes on to describe a layout of rows and columns. The problem is, as is usually the case, they are just putting the rows and columns on a window, not a user control. There must be something in the HeaderedContentControl. That's what I'm reading up on now.
  5. In Topic: A Couple More Layout Questions

    Posted 21 Jan 2015

    View PosttlhIn`toq, on 21 January 2015 - 12:39 PM, said:

    maybe I missed it, but where are you adding the UserControl to the the Tab?


    When I click the "Create new flight" command it fires the CreateNewFlight method
    
            void CreateNewFlight()
            {
                Flight newFlight = Flight.CreateNewFlight();
                FlightViewModel workspace = new FlightViewModel(newFlight, _flightRepository);
                this.Workspaces.Add(workspace);
                this.SetActiveWorkspace(workspace);
            }
    
    
    


    Which creates a new workspace in the Workspaces Collection which is rendered in the DataTemplate;
      <DataTemplate x:Key="WorkspacesTemplate">
          <TabControl 
          IsSynchronizedWithCurrentItem="True" 
          ItemsSource="{Binding}" 
          ItemTemplate="{StaticResource ClosableTabItemTemplate}"
          Margin="4"
          />
       </DataTemplate>
    
    
       <DataTemplate x:Key="ClosableTabItemTemplate">
          <DockPanel Width="120">
             <Button 
            Command="{Binding Path=CloseCommand}"
            Content="X"
            Cursor="Hand"
            DockPanel.Dock="Right"
            Focusable="False"
            FontFamily="Verdana" 
            FontSize="10"
            FontWeight="Bold"  
            Margin="0,1,0,0"
            Padding="0"
            VerticalContentAlignment="Bottom"
            Width="16" Height="16"
            />
             <ContentPresenter 
                Content="{Binding Path=DisplayName}" 
                VerticalAlignment="Center" 
                />
          </DockPanel>
       </DataTemplate>
    
    


    At least that is how I understand it. Of course, I have just begun. As I said, I have to take a little at a time and as I go I need each piece to work before I move on. As I understand it, the MVVM allows me to create any number of views since the ViewModel handles the data binding and other tasks without the view actually knowing about it. So there has to be something in the View I am creating to make sure it fills up whatever control it is going into.

My Information

Member Title:
D.I.C Head
Age:
Age Unknown
Birthday:
April 23
Gender:
Location:
Texas
Years Programming:
20
Programming Languages:
VB(A), HTML, ASP

Contact Information

E-mail:
Private

Friends

ScottinTexas hasn't added any friends yet.

Comments

ScottinTexas has no profile comments yet. Why not say hello?