Click here to Skip to main content
15,879,490 members
Home / Discussions / Mobile
   

Mobile

 
GeneralRe: Cross Platform Xamarin MVVM ListView binding to ViewModel List not working Pin
Stephen Holdorf20-Feb-19 4:48
Stephen Holdorf20-Feb-19 4:48 
QuestionXamarin Forms Picker binding Pin
Mycroft Holmes21-Dec-18 19:35
professionalMycroft Holmes21-Dec-18 19:35 
Questionmobile program Pin
Member 1408773812-Dec-18 20:07
Member 1408773812-Dec-18 20:07 
Questionreturn all html codes of page instead of one string (by B4A commands) Pin
Member 1352250115-Nov-18 20:38
Member 1352250115-Nov-18 20:38 
QuestionAdvice required Pin
Mycroft Holmes9-Nov-18 17:22
professionalMycroft Holmes9-Nov-18 17:22 
AnswerRe: Advice required Pin
Adrian Mikeliunas20-Nov-18 10:49
Adrian Mikeliunas20-Nov-18 10:49 
GeneralRe: Advice required Pin
Mycroft Holmes20-Nov-18 11:22
professionalMycroft Holmes20-Nov-18 11:22 
QuestionTapGestureRecognizer on an Image on Tab not work Pin
Vimalsoft(Pty) Ltd8-Nov-18 11:34
professionalVimalsoft(Pty) Ltd8-Nov-18 11:34 
Good Day All

i have images in a Listview ,i tried this on a normal Listview and also Telerik , it behaves the same. The Tab event is not fired consistently sometimes when i tap the images they dont respond to the Tap.

Here is my xaml
<telerikDataControls:RadListView  Grid.Row="1" x:Name="lstfun" BackgroundColor="Transparent">
                    <telerikDataControls:RadListView.ItemTemplate>
                        <DataTemplate>
                            <telerikListView:ListViewTemplateCell>
                                <telerikListView:ListViewTemplateCell.View>
                                    <Grid Padding="8,0,8,10" RowSpacing="0">
                                        <Grid Padding="1" BackgroundColor="#e1e1e3" RowSpacing="0">
                                            <Grid.RowDefinitions>
                                                <RowDefinition Height="*" />
                                                <RowDefinition Height="53" />
                                            </Grid.RowDefinitions>
                                            <Grid Grid.Row="0" Padding="0" BackgroundColor="#e4e4e4">
                                                <StackLayout>
                                                    <Label   Text="{Binding FUN_NAME}" FontFamily="Ubuntu" FontSize="14" TextColor="#9e9ea0" />
                                                    <Image  Source="HeaderBackground.png" HeightRequest="100" Aspect="AspectFill"/>
                                                    <Label  Text="{Binding DESCRIPTION}" FontFamily="Ubuntu-Medium" FontSize="14" TextColor="#3c3947" />
                                                </StackLayout>
                                            </Grid>
                                            <Grid Grid.Row="1" BackgroundColor="#ffffff" RowSpacing="0">
                                                <Grid   RowSpacing="0">
                                                    <Grid.RowDefinitions>
                                                        <RowDefinition Height="15" />
                                                        <RowDefinition Height="4" />
                                                        <RowDefinition Height="15" />
                                                    </Grid.RowDefinitions>

<pre>
                                                <StackLayout Padding="-25,12,0,0" Spacing="-100" Orientation="Horizontal">
                                                       <StackLayout Orientation="Vertical" >
                                                        <Image Source="chat.png" InputTransparent="false" HorizontalOptions="Center" HeightRequest="35" WidthRequest="150" >
                                                            <Image.GestureRecognizers>
                                                                <TapGestureRecognizer NumberOfTapsRequired="1" Tapped="TapGestureRecognizer_Tapped_4"/>
                                                            </Image.GestureRecognizers>
                                                        </Image>
                                                    </StackLayout>

                                                    <StackLayout Orientation="Vertical">
                                                        <Image Source="love.png" x:Name="imglike" InputTransparent="false"   HorizontalOptions="Center" HeightRequest="35" WidthRequest="150" >
                                                            <Image.GestureRecognizers>
                                                                <TapGestureRecognizer NumberOfTapsRequired="1" Tapped="TapGestureRecognizer_Tapped" />
                                                            </Image.GestureRecognizers>
                                                        </Image>
                                                    </StackLayout>

                                                    <StackLayout Orientation="Vertical">
                                                        <Image x:Name="imgfunin" Source="funin.png"  InputTransparent="false"  HorizontalOptions="Center" HeightRequest="35" WidthRequest="150" >
                                                            <Image.GestureRecognizers>
                                                                <TapGestureRecognizer  NumberOfTapsRequired="1" Tapped="TapGestureRecognizer_Tapped_1"/>
                                                            </Image.GestureRecognizers>
                                                        </Image>
                                                    </StackLayout>

                                                    <StackLayout Orientation="Vertical">
                                                        <Image Source="Fakenews.png" InputTransparent="false"  HorizontalOptions="Center" HeightRequest="35" WidthRequest="150" >
                                                            <Image.GestureRecognizers>
                                                                <TapGestureRecognizer  NumberOfTapsRequired="1" Tapped="TapGestureRecognizer_Tapped_2" />
                                                            </Image.GestureRecognizers>
                                                        </Image>
                                                    </StackLayout>

                                                    <StackLayout  Orientation="Vertical">
                                                        <Image Source="share.png" HorizontalOptions="Center" InputTransparent="false"  HeightRequest="35" WidthRequest="150" >
                                                            <Image.GestureRecognizers>
                                                                <TapGestureRecognizer  NumberOfTapsRequired="1" Tapped="TapGestureRecognizer_Tapped_3" />
                                                            </Image.GestureRecognizers>
                                                        </Image>
                                                    </StackLayout>
                                                </StackLayout> 
                                            </Grid>
                                        </Grid>
                                    </Grid>
                                </Grid>
                            </telerikListView:ListViewTemplateCell.View>
                        </telerikListView:ListViewTemplateCell>
                    </DataTemplate>
                </telerikDataControls:RadListView.ItemTemplate>
            </telerikDataControls:RadListView></pre>  

and the event handlers for my images TapGestureRecognizer_Tapped
<pre>private void TapGestureRecognizer_Tapped(object sender, EventArgs e)
          {

              DisplayAlert("", "Like Tabbed", "Ok");
          }

          private void TapGestureRecognizer_Tapped_1(object sender, EventArgs e)
          {
              DisplayAlert("", "Funin", "Ok");
          }

          private void TapGestureRecognizer_Tapped_2(object sender, EventArgs e)
          {
              DisplayAlert("", "Fake News Tabbed","Ok");

          }

          private void TapGestureRecognizer_Tapped_3(object sender, EventArgs e)
          {

              DisplayAlert("", "Shareout Tabbed", "Ok");
          }

          private void TapGestureRecognizer_Tapped_4(object sender, EventArgs e)
          {

              DisplayAlert("", "Comment Tabbed", "Ok");
          }</pre>

Thanks
Vuyiswa Maseko,

Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code.

C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vimalsoft.com
vuyiswa[at]vimalsoft.com

Questionprayer time Pin
Sayed Gulab Hussain Shah3-Nov-18 22:30
Sayed Gulab Hussain Shah3-Nov-18 22:30 
AnswerRe: prayer time Pin
OriginalGriff3-Nov-18 22:32
mveOriginalGriff3-Nov-18 22:32 
AnswerRe: prayer time Pin
Afzaal Ahmad Zeeshan4-Nov-18 9:32
professionalAfzaal Ahmad Zeeshan4-Nov-18 9:32 
QuestionQuestion about copyright laws Pin
ericbruhaha23-Oct-18 15:21
ericbruhaha23-Oct-18 15:21 
AnswerRe: Question about copyright laws Pin
Richard MacCutchan23-Oct-18 22:36
mveRichard MacCutchan23-Oct-18 22:36 
AnswerRe: Question about copyright laws Pin
abayomicharm24-Oct-18 19:44
abayomicharm24-Oct-18 19:44 
AnswerRe: Question about copyright laws Pin
Eddy Vluggen25-Oct-18 1:10
professionalEddy Vluggen25-Oct-18 1:10 
GeneralRe: Question about copyright laws Pin
ericbruhaha25-Oct-18 6:42
ericbruhaha25-Oct-18 6:42 
GeneralRe: Question about copyright laws Pin
Eddy Vluggen25-Oct-18 7:48
professionalEddy Vluggen25-Oct-18 7:48 
GeneralRe: Question about copyright laws Pin
ericbruhaha25-Oct-18 8:05
ericbruhaha25-Oct-18 8:05 
GeneralRe: Question about copyright laws Pin
Eddy Vluggen25-Oct-18 8:11
professionalEddy Vluggen25-Oct-18 8:11 
QuestionUpdating a ListView from a Service Every 5 seconds Pin
Vimalsoft(Pty) Ltd15-Oct-18 0:32
professionalVimalsoft(Pty) Ltd15-Oct-18 0:32 
AnswerRe: Updating a ListView from a Service Every 5 seconds Pin
Afzaal Ahmad Zeeshan24-Oct-18 0:38
professionalAfzaal Ahmad Zeeshan24-Oct-18 0:38 
GeneralRe: Updating a ListView from a Service Every 5 seconds Pin
Vimalsoft(Pty) Ltd27-Oct-18 11:46
professionalVimalsoft(Pty) Ltd27-Oct-18 11:46 
QuestionHow to send data from websql to server mysql using ajax php Pin
Member 1290096918-Sep-18 20:03
Member 1290096918-Sep-18 20:03 
AnswerRe: How to send data from websql to server mysql using ajax php Pin
Richard MacCutchan18-Sep-18 21:34
mveRichard MacCutchan18-Sep-18 21:34 
QuestionXamarin Forms UWP Deployment Issue Pin
Kevin Marois24-Jul-18 6:06
professionalKevin Marois24-Jul-18 6:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.