This is a migrated thread and some comments may be shown as answers.

Base and Derived Grid View - XAML issue

4 Answers 18 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Aleksander
Top achievements
Rank 1
Aleksander asked on 06 Jul 2011, 01:38 PM
Hi,

is it possible to create base user control with GridView without column definition
and then to provide later that columns definition in XAML of other user control
that has that base user control embedded inside (so base user control with GridView
is child control of other user control)?

I created DependencyProperty on base user control level that exposes Telerik GridView,
but in user control that has this user control as a child control I can't override GridView object
or change column definition. I mean I provided such Grig/Column definition on parent/outer
user control and XAML compilation works ok, but I see test column defined on base user control
all the time...

Regards,
Alek

4 Answers, 1 is accepted

Sort by
0
Swapnil
Top achievements
Rank 1
answered on 20 Apr 2018, 06:12 AM
unble to launch nunit
string stdNunitPath = "C:\\TMS\\bin";
nUnitPath = stdNunitPath + "\\nunit-console.exe";
 executionArgs[0] = "\"" + testDLLpath + "\" /include:";
executionArgs[1] = " /domain=Multiple /process=Multiple  /out=";
 executionArgs[2] = ".txt /err=DaronErrFile.txt";


// string theseArgs = "\"" + strBuildPath + "\\TMSoAutomation.dll\" /include:" + runTestCase + " /domain=Multiple /process=Multiple  /out=" + runTestCase + ".txt /err=DaronErrFile.txt";
//           string thisFile = strAVSPath + "\\TMSTestApp\\T3SD_UseReporter\\bin\\Release\\" + runTestCase + ".txt";




Process process = new Process();
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] created new process instance");


                       ProcessStartInfo startInfo = new System.Diagnostics.ProcessStartInfo();
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] created new processStartInfo instance");


                       startInfo.WindowStyle = ProcessWindowStyle.Hidden;
              //         startInfo.WindowStyle = ProcessWindowStyle.Normal;


                       string strMyDocuments = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
                       string strAVSPath = strMyDocuments + "\\AVS\\Projects";
                       string strBuildPath = strMyDocuments + "\\AVS";
                       startInfo.FileName = nUnitPath;
                       log("Runtime NunitPath [" + nUnitPath + "]");
                      Console.WriteLine("Nunit Path: [" + nUnitPath  + "]");
  //                     string theseArgs = "\"" + strAVSPath + "\\Daron0004\\Daron0004\\bin\\Debug\\Daron0004.dll\" /include:" + runTestCase + " /domain=Multiple /process=Multiple  /out=" + runTestCase + ".txt /err=DaronErrFile.txt";
                       string theseArgs = executionArgs[0] + runTestCase + executionArgs[1] + runTestCase + executionArgs[2];
                       log("Execution args [" + theseArgs + "]");
                       log("Command Sent [" + nUnitPath + " " + theseArgs + "]");
                       Console.WriteLine("Args: [" + theseArgs  + "]");




                       string thisFileOld = strAVSPath + "\\TMSTestApp\\T3SD_UseReporter\\bin\\Release\\" + runTestCase + ".txt";
                     //  string thisFile = postRunFilePath + runTestCase + ".txt";
                       string thisFile = System.IO.Path.GetFullPath("./") + runTestCase + ".txt";
                       Console.WriteLine("FilePath: [" + thisFile + "]");


  //                     MessageBox.Show(nUnitPath + "]  [" + theseArgs + "outfile [" + thisFile  + "]");
                       startInfo.Arguments = theseArgs;
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] created new processStartInfo instance");


                       string processExitCode = "";
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] Just before getting StartInfo");


                       process.StartInfo = startInfo;
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] Just after getting StartInfo, before process start");
                       log("Starting test execution ["+ DateTime.Now +"]");
                       process.Start();
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] Just after process start");
                       string thisProcessName = process.ProcessName;
                       Console.WriteLine("thread [" + thisThreadNumber.ToString() + "] this process name [" + thisProcessName + "]");

0
Swapnil
Top achievements
Rank 1
answered on 20 Apr 2018, 06:18 AM

<Window x:Class="T3SD_UseReporter.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:local="clr-namespace:T3SD_UseReporter"
        Title="Gherkin Test Execution v1.52"  WindowState="Maximized" >
    <Grid x:Name="T3SD_Useage_Reporter" Background="#FFE7EAF0">
        <Button x:Name="btnRunExe" Content="Run Tests" Height="26" Margin="0,4,10,0" VerticalAlignment="Top"  Click="RunExe" HorizontalAlignment="Right" Width="74"/>
        <Label x:Name="lblQueryType" Content="" HorizontalAlignment="Left" Height="24" Margin="452,131,0,0" VerticalAlignment="Top" Width="112"/>
        <Label x:Name="lblRecordsPerDay" Content="" HorizontalAlignment="Left" Height="28" Margin="10,175,0,0" VerticalAlignment="Top" Width="155"/>
        <Label x:Name="lblRunComplete" Content="Finished" Margin="660,127,84,0" HorizontalContentAlignment="Center" VerticalAlignment="Top"/>
        <Label x:Name="lblRunning" Content="In Progress" HorizontalAlignment="Left" Margin="492,127,0,0" HorizontalContentAlignment="Center" VerticalAlignment="Top" Width="163"/>
        <Label x:Name="lblALM" Content="ALM URL" HorizontalAlignment="Left" Margin="6,21,0,0" HorizontalContentAlignment="Left" VerticalAlignment="Top" Width="517"/>
        <Label x:Name="lblInQueue" Content="In Queue" HorizontalAlignment="Left" Margin="324,127,0,0" HorizontalContentAlignment="Center" VerticalAlignment="Top" Width="164"/>
        <TextBox x:Name="txtMessageArea" Height="24" Margin="90,5,220,0" TextWrapping="Wrap" Text="Root" VerticalAlignment="Top"/>
        <Label x:Name="lblTestLabRoot" Content="Message Area" HorizontalAlignment="Left" Margin="-3,5,0,0" HorizontalContentAlignment="Right" VerticalAlignment="Top" Width="93"/>
        <TextBox x:Name="tbIQ" Margin="324,154,0,10" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" TextWrapping="NoWrap" FontSize="14" Text="-Empty-" HorizontalAlignment="Left" Width="162"/>
        <TextBox x:Name="tbIP" Margin="493,154,0,10" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" TextWrapping="NoWrap" FontSize="14" Text="-Empty-" HorizontalAlignment="Left" Width="162"/>
        <TextBox x:Name="tbComplete" Margin="661,154,10,10" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" TextWrapping="NoWrap" FontSize="16" Text="-Empty-"/>
        <Button x:Name="btnReset" Content="Requeue Fails" Height="26" Margin="0,5,136,0" VerticalAlignment="Top"  Click="btnReset_Lists" HorizontalAlignment="Right" Width="80" RenderTransformOrigin="4.324,-0.269"/>
        <Label x:Name="lblInQueueCount" Content="" HorizontalAlignment="Left" Margin="430,127,0,0" HorizontalContentAlignment="Right" VerticalAlignment="Top" Width="55"/>

0
Swapnil
Top achievements
Rank 1
answered on 20 Apr 2018, 06:19 AM



        <Label x:Name="lblRunningCount" Content="" HorizontalAlignment="Left" Margin="624,127,0,0" HorizontalContentAlignment="Right" VerticalAlignment="Top" Width="30"/>
        <Label x:Name="lblRunCompleteCount" Content="" Margin="738,108,19,0" HorizontalContentAlignment="Right" VerticalAlignment="Top" FontSize="28"/>
        <TextBox x:Name="txtTestSet" Height="24" Margin="453,40,178,0" Visibility="Hidden" TextWrapping="Wrap" Text="Root" VerticalAlignment="Top" />


        <Button x:Name="btnAddToQueue" Content="Add to Queue --&gt;&gt;&gt;" HorizontalAlignment="Left" Margin="198,154,0,0" Width="121"  Click="btnfnAddToQueue" Height="22" VerticalAlignment="Top"/>
        <Button x:Name="btnLoadTestLabTree" Content="Load TestLab Tree" HorizontalAlignment="Left" Margin="10,152,0,0" Width="125"  Click="btnfnLoadTestLabTree" Height="22"  VerticalAlignment="Top"/>
        <TabControl x:Name="tabControl01" HorizontalAlignment="Left" Margin="10,180,0,10" Width="308" SelectionChanged="tabControl01_SelectionChanged">
            <TabItem Header="Filter" Name="Tab1">
                <Grid x:Name="FilterTabGrid" Background="#FFE5E5E5" Margin="0,0,0,-8"/>
            </TabItem>
            <TabItem Header="Test Lab Tree" Name="Tab0" >
                <TreeView x:Name="tvTestLab" HorizontalAlignment="Left" Margin="0,-1,-2,-4"  Width="300">
                    <Style TargetType="{x:Type TreeViewItem}">
                        <Style.Triggers>
                            <Trigger Property="IsSelected" Value="True">
                                <Setter Property="Background" Value="Yellow"/>
                            </Trigger>
                        </Style.Triggers>
                    </Style>
                </TreeView>
            </TabItem>




            <TabItem Header="Machines">
                <Grid Background="#FFE5E5E5" Margin="0,4,0,-4">
                    <Viewbox x:Name="viewbox1" Margin="10,10,11,0" Stretch="Fill" Height="66" VerticalAlignment="Top">
                        <Grid Height="66" Width="277">
                            <TextBox x:Name="tbMachineName1" HorizontalAlignment="Left" Height="23" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="277"/>
                            <Label Content="Online" HorizontalAlignment="Left" Margin="0,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="Running" HorizontalAlignment="Left" Margin="73,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="Elapsed" HorizontalAlignment="Left" Margin="165,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="P|F|T" HorizontalAlignment="Left" Margin="238,16,0,0" VerticalAlignment="Top"/>
                            <Label x:Name="lblElapsed1" Content="0" HorizontalAlignment="Left" Margin="165,37,0,0" VerticalAlignment="Top"/>
                            <Ellipse x:Name="OnlineEllipse1" Fill="#FFF4F4F5" Stroke="Black" Margin="10,37,246,10"/>
                            <Ellipse x:Name="RunningEllipse1" Fill="#FFF4F4F5" Stroke="Black" Margin="88,37,168,10"/>
                            <Label x:Name="passFailLabel1" Content="0|0|0" HorizontalAlignment="Left" Margin="238,37,0,0" VerticalAlignment="Top"/>


                        </Grid>
                    </Viewbox>
                    <Viewbox x:Name="viewbox01_Copy" Margin="10,72,11,0" Stretch="Fill" Height="66" VerticalAlignment="Top">
                        <Grid Height="66" Width="277">
                            <TextBox HorizontalAlignment="Left" Height="23" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="277"/>
                            <Label Content="Online" HorizontalAlignment="Left" Margin="0,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="Running" HorizontalAlignment="Left" Margin="73,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="Elapsed" HorizontalAlignment="Left" Margin="165,16,0,0" VerticalAlignment="Top"/>
                            <Label Content="P|F|T" HorizontalAlignment="Left" Margin="238,16,0,0" VerticalAlignment="Top"/>
                            <Label x:Name="lblElapsed2" Content="0" HorizontalAlignment="Left" Margin="165,37,0,0" VerticalAlignment="Top"/>
                            <Ellipse x:Name="OnlineEllipse2" Fill="#FFF4F4F5" Stroke="Black" Margin="10,37,246,10"/>
                            <Ellipse x:Name="RunningEllipse2" Fill="#FFF4F4F5" Stroke="Black" Margin="88,37,168,10"/>
                            <Label x:Name="passFailLabel2" Content="0|0|0" HorizontalAlignment="Left" Margin="238,37,0,0" VerticalAlignment="Top"/>
                        </Grid>
                    </Viewbox>
                </Grid>
            </TabItem>


        </TabControl>
        <!--

0
Swapnil
Top achievements
Rank 1
answered on 20 Apr 2018, 06:21 AM



        <TabControl x:Name="tabControl02" HorizontalAlignment="Left" Margin="11,34,0,0" Width="308" SelectionChanged="tabControl01_SelectionChanged" Height="88" VerticalAlignment="Top">
            <TabItem Header="Loaded Items" Name="Tab2_1">
        -->
        <ListBox x:Name="lbLoadedItems" Margin="10,42,0,0" HorizontalAlignment="Left" Height="80" Width="253" VerticalAlignment="Top"/>
        <!--
    </TabItem>
            <TabItem Header="Fail Spots" Name="Tab2_2">
                <ListBox x:Name="lbFailLines" Margin="10,95,0,0" HorizontalAlignment="Left" Height="80" Width="307" VerticalAlignment="Top"/>
            </TabItem>
        </TabControl>
        -->
        <ComboBox x:Name="cbQueueFilter" HorizontalAlignment="Left" Margin="198,127,0,0" VerticalAlignment="Top" Width="120">
            <ComboBoxItem Content="Not Passed" ></ComboBoxItem>
            <ComboBoxItem Content="All Tests" IsSelected="True"></ComboBoxItem>
            <ComboBoxItem Content="Failed"></ComboBoxItem>
            <ComboBoxItem Content="No Run"></ComboBoxItem>


        </ComboBox>
        <Button x:Name="btnDeleteQueue" Content="X" HorizontalAlignment="Left" Margin="324,127,0,0" Width="23"  Click="btnfnDeleteQueue" Height="22" VerticalAlignment="Top"/>
        <Button x:Name="btnStopRun" Content="Stop" Height="26" Margin="0,5,89,0" VerticalAlignment="Top"  Click="StopRun" HorizontalAlignment="Right" Width="42"/>
        <ListBox x:Name="lbFailLines" Margin="326,42,10,0" Height="80" SelectionMode="Multiple" SelectionChanged="ListBoxSelectionChanged" VerticalAlignment="Top"/>
        <Button x:Name="btnCopyFailsToClipboard" Content="Copy Fails" HorizontalAlignment="Left" Margin="10,126,0,0" Width="125"  Click="btnfnCopyFailuresToClipboard" Height="22"  VerticalAlignment="Top"/>
        <Button x:Name="btnKillNunit"  Background="Red"  HorizontalAlignment="Left" Margin="268,47,0,0" Width="53"  Click="btnfnKillNunit" Height="47"  VerticalAlignment="Top">
            <TextBlock Text="Kill Nunit" TextWrapping="Wrap" TextAlignment="Center"/>
        </Button>
        <ComboBox x:Name="cbTimeout" HorizontalAlignment="Left" Margin="269,99,0,0" VerticalAlignment="Top" Width="50">
            <ComboBoxItem Content="1" />
            <ComboBoxItem Content="2" />
            <ComboBoxItem Content="3" />
            <ComboBoxItem Content="4" />
            <ComboBoxItem Content="5" />
            <ComboBoxItem Content="8" />
            <ComboBoxItem Content="10" />
            <ComboBoxItem Content="15" />
            <ComboBoxItem Content="20"  IsSelected="True"/>
            <ComboBoxItem Content="30"/>
            <ComboBoxItem Content="60"/>
        </ComboBox>




    </Grid>
</Window>

Tags
GridView
Asked by
Aleksander
Top achievements
Rank 1
Answers by
Swapnil
Top achievements
Rank 1
Share this question
or