Gratz 😃
EDIT: Yeah, bei mir passt auch der Papphut 😄
Hallo,
ich bin gestern dann auch darauf gekommen, das diese Metadaten ja gar nicht per WSDL publiziert werden und somit auch nicht im Client bekannt sein können. Trotzdem vielen Dank!
Gruß David
Hallo,
ich biete größere Bilder (~300kb) per WCF Service an mit folgender Konifguration:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="basicHttpBindingWithMtom" maxBufferSize="1048576"
maxBufferPoolSize="1048576" maxReceivedMessageSize="1048576"
messageEncoding="Mtom" />
</basicHttpBinding>
<netTcpBinding>
<binding name="netTcpBindingForLargeMessages" maxBufferPoolSize="1048576"
maxBufferSize="1048576" maxReceivedMessageSize="1048576">
<readerQuotas maxArrayLength="1048576" maxBytesPerRead="1048576" />
</binding>
</netTcpBinding>
</bindings>
<behaviors>
<serviceBehaviors>
<behavior name="LiveProxyBehavior">
<serviceMetadata httpGetEnabled="true" httpGetUrl="" />
</behavior>
</serviceBehaviors>
</behaviors>
<services>
<service behaviorConfiguration="LiveProxyBehavior" name="WINSTON.Record.Recorder.LiveProxy.LiveProxyService">
<endpoint address="" behaviorConfiguration="" binding="basicHttpBinding"
bindingConfiguration="basicHttpBindingWithMtom" name="HttpEndpoint"
contract="ILiveViewContract" />
<endpoint binding="netTcpBinding" bindingConfiguration="netTcpBindingForLargeMessages"
name="TcpEndpoint" contract="ILiveViewContract" />
<host>
<baseAddresses>
<add baseAddress="http://localhost:6515/LiveProxy/DavidBuero" />
<add baseAddress="net.tcp://localhost:6516/LiveProxy/DavidBuero" />
</baseAddresses>
</host>
</service>
</services>
</system.serviceModel>
Also die MessageSize-Eigenschaft ist für beide Bindings auf ca. 1MB festgelegt. Aber irgendwie wird das beim erstellen des Services einfach ignoriert und taucht nicht in der WSDL-Beschreibung auf und dementsprechend auch nicht in der config wenn ich es mit dem WcfTestClient teste:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="HttpEndpoint" closeTimeout="00:01:00" openTimeout="00:01:00"
receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false"
bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
messageEncoding="Mtom" textEncoding="utf-8" transferMode="Buffered"
useDefaultWebProxy="true">
<readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<security mode="None">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="" />
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
</binding>
</basicHttpBinding>
<netTcpBinding>
<binding name="TcpEndpoint" closeTimeout="00:01:00" openTimeout="00:01:00"
receiveTimeout="00:10:00" sendTimeout="00:01:00" transactionFlow="false"
transferMode="Buffered" transactionProtocol="OleTransactions"
hostNameComparisonMode="StrongWildcard" listenBacklog="10"
maxBufferPoolSize="524288" maxBufferSize="65536" maxConnections="10"
maxReceivedMessageSize="65536">
<readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<reliableSession ordered="true" inactivityTimeout="00:10:00"
enabled="false" />
<security mode="Transport">
<transport clientCredentialType="Windows" protectionLevel="EncryptAndSign" />
<message clientCredentialType="Windows" />
</security>
</binding>
</netTcpBinding>
</bindings>
<client>
<endpoint address="http://localhost:6515/LiveProxy/DavidBuero"
binding="basicHttpBinding" bindingConfiguration="HttpEndpoint"
contract="ILiveViewContract" name="HttpEndpoint" />
<endpoint address="net.tcp://localhost:6516/LiveProxy/DavidBuero"
binding="netTcpBinding" bindingConfiguration="TcpEndpoint"
contract="ILiveViewContract" name="TcpEndpoint">
<identity>
<userPrincipalName value="XXX" />
</identity>
</endpoint>
</client>
</system.serviceModel>
</configuration>
Was ist das Problem? Funktioniert es nicht wenn ich 2 Bindings eine Konfiguration mitgebe?
Gruß David
Wenn man benutzerdefinierte Sections haben möchte, kommt man mit dem VS Designer leider nicht mehr aus.
Doch das Tool muss angepasst werden csd.codeplex.com
Gruß David
Hallo,
ich habe einen TestFiles Ordner in dem ich dateien schreibe, die während einem UnitTest gebraucht werden, aber jedes Mal, wenn ich eine Datei schreibe, bekomme ich eine Exception weil ich angeblich keinen Zugriff auf das Verzeichnis habe. In dem Verzeichnis hat allerdings JEDER Vollzugriff...
Jemand eine Ahnung was das ist?
Gruß David
Hey,
normal verwende ich zum Erstellen von Configurationsabschnitten den Configuration Section Designer, der auch wirklich genial ist. Nun wurde das Tool leider nicht an VS2010 angepasst und ich kann es nicht installieren. Kennt ihr noch ein ähnliches Tool das man dazu verwenden könnte? Weil das von Hand zu coden wäre echt stundenlange stupide arbeit...
Gruß David
Also mit der DataGrudComboBoxColum funktioniert das ganze nicht, wenn ich daraus eine TemplateColum mache und der eine Combobox hinzufüge funktioniert das ganze super... Ka was das für ein Fehler ist!
Gruß David
Hallo,
ich habe ein Fenster und nutze die this als DataContext. Innerhalb des Fensters habe ich ein DataGrid, welches ich an eine Liste X binde. In dem Datagrid habe ich eine Combobox, welche nicht an Liste X sondern an den DataContext des Fensters gebunden werden soll. Mit google habe ich nun zig Beispiele gefunden bei denen es mit RelativeBindings gelöst ist, das habe ich auch probiert, aber es funktioniert nicht:
<Window x:Class="NewCourseRegistration"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Neue Anmeldung für einen Kurs" Height="450" Width="405">
<DockPanel>
<Grid DockPanel.Dock="Top" Height="58">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="168" />
<ColumnDefinition Width="215*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="29" />
<RowDefinition Height="29" />
</Grid.RowDefinitions>
<Label Content="Datum:" Grid.RowSpan="2" Height="28" HorizontalAlignment="Left" Margin="0" Name="label1" VerticalAlignment="Top" />
<Label Content="Notfallnummer:" Grid.Row="1" Grid.RowSpan="2" Height="28" HorizontalAlignment="Left" Margin="0" Name="label2" VerticalAlignment="Top" />
<DatePicker SelectedDate="{Binding SelectedDate}" Grid.Column="1" Grid.RowSpan="2" Height="25" HorizontalAlignment="Left" Margin="0" Name="datePicker1" VerticalAlignment="Top" Width="115" />
<TextBox Text="{Binding PhoneNr}" Grid.Column="1" Grid.Row="1" Height="23" HorizontalAlignment="Left" Name="textBox1" VerticalAlignment="Top" Width="180" />
</Grid>
<StackPanel DockPanel.Dock="Bottom" Height="30">
</StackPanel>
<DataGrid ItemsSource="{Binding Entities, Mode=TwoWay}" DockPanel.Dock="Top" AutoGenerateColumns="False" CanUserAddRows="True">
<DataGrid.Columns>
<DataGridTextColumn Header="Name" Binding="{Binding Name}"/>
<DataGridTextColumn Header="Alter" Binding="{Binding Age}"/>
<DataGridComboBoxColumn Header="Kategorie" ItemsSource="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Window}}, Path=DataContext.Types}" SelectedItemBinding="{Binding Category}"/>
<DataGridComboBoxColumn Header="Fähigkeit"/>
<DataGridTextColumn Header="Tage" Binding="{Binding Days}"/>
</DataGrid.Columns>
</DataGrid>
</DockPanel>
</Window>
Fehlermeldung ist:
System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Window', AncestorLevel='1''. BindingExpression:Path=DataContext.Types; DataItem=null; target element is 'DataGridComboBoxColumn' (HashCode=44946895); target property is 'ItemsSource' (type 'IEnumerable')
Wo mache ich den Fehler?
Gruß David
unsafe und mit Pointern kopieren! Ist schnell und einfach zu implementieren!
Gruß David
Hey,
natürlich ist es das. Einfach die Phone 7 Tools runterladen, installieren und dann hast du die entsprechenden Vorlagen im VS und zusätzlich einen Emulator für das Device und noch Expression Blend mit Vorlagen für das Phone.
Gruß David