How to pass a variable to the SelectCommand of a SqlDataSource?

Try this instead, remove the SelectCommand property and SelectParameters: <asp:SqlDataSource ID=”SqlDataSource1″ runat=”server” ConnectionString=”<%$ ConnectionStrings:itematConnectionString %>”> Then in the code behind do this: SqlDataSource1.SelectParameters.Add(“userId”, userId.ToString()); SqlDataSource1.SelectCommand = “SELECT items.name, items.id FROM items INNER JOIN users_items ON items.id = users_items.id WHERE (users_items.user_id = @userId) ORDER BY users_items.date DESC” While this worked for me, the following code also … Read more

In WPF Stretch a control to fill a ListView Column

After narrowing down my question I was about to Google and find an answer here. Basically for some reason the ListViewItems are set to align to the Left. Setting them to Stretch fixes this problem. This is done through a style like so: <ListView.ItemContainerStyle> <Style TargetType=”ListViewItem”> <Setter Property=”HorizontalContentAlignment” Value=”Stretch” /> </Style> </ListView.ItemContainerStyle> This unfortunately affects … Read more

Change selected and unfocused Listbox style to not be grayed out

I have done something like this using the following in a merged ResourceDictionary, it may help you: <Style TargetType=”ListBoxItem”> <Style.Resources> <!–SelectedItem with focus–> <SolidColorBrush x:Key=”{x:Static SystemColors.HighlightBrushKey}” Color=”LightBlue” Opacity=”.4″/> <!–SelectedItem without focus–> <SolidColorBrush x:Key=”{x:Static SystemColors.InactiveSelectionHighlightBrushKey }” Color=”LightBlue” Opacity=”.4″/> </Style.Resources> </Style>

How to use the dotnet-pack –version-suffix with csproj?

According the documentation, the Version property override the version on packing, instead, use the VersionPrefix. <PropertyGroup> <VersionPrefix>1.0.0</VersionPrefix> </PropertyGroup> And use the command to pack solution: dotnet pack –version-suffix beta Optionally you can set VersionPrefix and VersionSuffix in .csproj file. <PropertyGroup> <VersionPrefix>1.0.0</VersionPrefix> <VersionSuffix>alpha</VersionSuffix> </PropertyGroup>

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)