小编Ash*_*mar的帖子

在Xaml中设置网格行的最小或最大高度(Xamarin.Forms)

我需要使用Xaml或后面的代码设置Xamarin.Forms中的a RowDefinition的最小高度Grid.我找不到像MinHeight或MaxHeight这样的房产.只有高度属性RowDefinition.

<Grid ColumnSpacing="10" Padding="20">
    <Grid.RowDefinitions>
        <RowDefinition Height="*"/>
    </Grid.RowDefinitions>
</Grid>
Run Code Online (Sandbox Code Playgroud)

c# xaml gridview xamarin xamarin.forms

4
推荐指数
1
解决办法
9791
查看次数

在Rails中使用参数的Jquery Ajax POST请求(Ruby on Rails)

我想在rails应用程序中发出ajax post请求.但我得到的回应是错误的.

Rails代码: -

def search_exams(myparam1 , myparam2)
   json_data = {:aaData=> [["abc","xyz","lmnop"],["sdf","adsdf","sadfsd"],["sdf","adsdf","sadfsd"]]}.to_json
   respond_to do |format|
     format.json { render :json => json_data }
   end
end
Run Code Online (Sandbox Code Playgroud)

脚本代码: -

<%= javascript_tag "window._token = '#{form_authenticity_token}'" %>


<script>
$.ajax({
        url:'/home/search_exams',
        type:'POST',
        dataType:'json',
        data:{
            myparam1: "First Param value",
            myparam2: "Second param value",
            authenticity_token: window._token
        },
        success:function(data){
            debugger;
        },
        error:function(data){
            debugger;
        }
    });
  </script>
Run Code Online (Sandbox Code Playgroud)

我收到这个错误: -

"HomeController中的ArgumentError#search_exams错误的参数数量(0表示2)Rails.root:C:/ Users/........"

ajax jquery ruby-on-rails ruby-on-rails-4

3
推荐指数
1
解决办法
7739
查看次数

我们如何在android中使用粗边框(某种颜色)和白色背景制作EditText?

我得到了一些代码,但没有得到 -

<shape xmlns:android="http://schemas.android.com/apk/res/android" 
       android:thickness="0dp" 
       android:shape="rectangle">

  <stroke android:width="2dp"
         android:color="#00cc33"/>

</shape>
Run Code Online (Sandbox Code Playgroud)

它提供边框颜色,但背景颜色为黑色.提前致谢...

android styles android-edittext android-styles

1
推荐指数
1
解决办法
6833
查看次数