User Profile & Activity

Arief Handany Member
Page
of 20
Posted: April 8, 2015 1:49 AM

Hi jimmy,

I actually successfully replicated it, here is the always replicated behaviour if you interested

Input data with the same name more than 2 times affect other data with the same name when implemented in categorized list:

  • at least 3 Data in the same category with same name: when user strike-through the third data , the first or the second data will be stroke
  • at least 3 Data in the same category with 1 or more data in other category with same name: when user strike-through the data in other category, the second data in previous category will be stroke
  • if you apply the again then removstrikethrough e, bugged strikethrough will dissappear

yeah looks like it only affect IOS, i already test it in Android, WinPhone, and WinRT

Our developer already aware about this issue and already going into April 2015 Sprint

Please stay tune for hotfix build!

Best Regards
Arief

Hi Leo,

I already inform the requested feature to our programmer (CommandProperty Binding in Custom View Slider - CROS-798), i will update you with the information regarding the Feature Request.

Stay tuned for our newest build! :)

Best Regards,
Arief

Hi Jimmy

Thank you for your information,

Please if there are any more question, feel free to ask!

Best Regards
Arief

Hi Leo, 

Even though i already use the newest crosslight assemblies looks like the error is still there, i already report your issue to our programmer (duplication & error ones) with code CROS-796 and CROS 797, i will update you with new information about the fix.

Meanwhile i'm suggesting using only byte[] image data (ImageProperty) using ImageProperty i encounter no error (use ImageMemberPath or not) hope that helps

Best Regards
Arief

Posted: March 30, 2015 10:15 AM

Hi Cristobal,

First of all, you must create a Custom GridViewCell, because our GridViewCell doesn't have id that can be used to bind with the cell background, so you must make a Custom one including the id inside the layout.

Please remember that you only need this code inside your view model to access data from model and repository or local List<> : this.SourceItems = this.Repository.GetAll().ToObservable();

Next to connect with the background color, there are however there are two method to access the value from the data

First Method is you can manipulate your model by adding this:

 public StyleAttributes ColorStyle        {            get            {                return new StyleAttributes(){
                    BackgroundColor=(this.Color == Red)?Color.FromArgb(0xff,0xff,0x00,0x00):Color.FromArgb(0xff,0xff,0xff,0xff)
}; } }

Note you can change Color.FromArgb with our premade color using for example: Colors.Red or Colors.Transparent, also remember to add 0x before hex code because it only accept byte

Then inside your binding provider you can add:

itemBinding.AddBinding("YourCellBackgroundID", BindableProperties.StyleAttributesProperty, new BindingDescription("ColorStyle"));

This could be done because when you can call List/Grid type you can also access your model from there

Another method you can use is converter:

Add this inside your binding provider:

itemBinding.AddBinding("YourCellBackgroundID", BindableProperties.StyleAttributesProperty, new BindingDescription("Color"){ Converter = new ColorConverter()});


Make new file named ColorConverter with class ColorConverter and insert this inside:

	public class ColorConverter: IValueConverter
{ #region IValueConverter implementation public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { if (value is String) { int CatColor = (String)value; if (CatColor == "Red") { StyleAttributes style = new StyleAttributes(); style.BackgroundColor = Colors.Red; return style; } else { StyleAttributes style = new StyleAttributes(); style.BackgroundColor = Colors.White; return style; } } return null; } public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { throw new System.NotImplementedException(); } #endregion }

Connect your binding provider with this converter

So in conclusion, i think the second method is more cleaner and doesn't manipulate the model too much... The only file you actually need to changes is just the Layout and Binding Provider (also model or converter)

You can also see this kind of implementation in our samples: http://git.intersoftpt.com/projects/CROS/repos/samples/browse/MyInventory


Hope that helps :)

Best Regards,
Arief

Hi Leo,

Sorry for the late response, in IOS you actually MUST bind the first ImageView using member path like this: 

  ItemBindingDescription itemBinding = new ItemBindingDescription                                                 {                                                     //DisplayMemberPath = "Name",
                                                     //DetailMemberPath = "Location",
                                                     ImageMemberPath = "ResolvedThumbnailImage",
                                                     //ImagePlaceholder = "item_placeholder.png"
                                                 };
			itemBinding.AddBinding("ItemImageView", BindableProperties.ImageSourceProperty, "ResolvedThumbnailImage");

			itemBinding.AddBinding("TestImageView", BindableProperties.ImageSourceProperty, "ResolvedTestImage");
			itemBinding.AddBinding("TestImageView", BindableProperties.IsVisibleProperty, "Sold");

ImageMemberPath will be default-ly bind to "ImageView" name so reserved that name to the first image you want to bind

So in example above: your first image must be binded to image member path, and second image to "TestImageView"

If the error still persist please inform us :)

Best regards, 
Arief

Hi Jimmy, 

Looks like the problem have already been fixed by our programmer in the newest version (Crosslight 3.0.5000.226) it contain bug fixes for ListFragment (for example like navigation to the same view model bug) also please be aware that we also updated some of our samples.

I use version 226 and data samples with drawer, i modified the samples to use nested list (list navigate to more list then to detail) and it is working :) (217 not working and send error like your samples)

If the problem still persist please inform us thanks :)

Best regards, 
Arief

Hi Jimmy

Sorry for the late respond, currently i still investigating this issue i will give you update regarding this issue, in the mean time i guess you should use your own workaround, sorry.

Best Regards,
Arief

Posted: March 26, 2015 9:45 AM

Hi Jimmy


Thanks for your information. I have report this to Crosslight development team under 'CROS-793'. I will update you with information about this issue.

Best Regards,
Arief

Edit: typo issue number

Hi Jimmy,
Sorry for late response,

I see, i will try to create related entities in edmx, also can i see your models .cs file. My plan is i will create new entities name imagedetail and connected to the item, the byte will be in the imagedetail

Also could you (its ok if you couldn't) temporarily add this to your project: http://git.intersoftpt.com/projects/CROS/repos/frameworks/browse/Intersoft.AppFramework then: 

  • remove references Intersoft.AppFramework change the reference with this project
  • open you .cs file that contain InitializeSaveRequest and entities.OfType
  • press the references and double click the this.InitializeSaveRequest(request, entities);
  • please check this line of code IEnumerable<IEntity> entities = this.EntityContainer.PrepareSavedEntities();, does the program return entities?
Is the code working (entities.OfType<Item>()) when it put inside simple entities?

I guess our crux of problem now lies in entities.OfType because the data actually inputable to database except the file

Best Regards
Arief




All times are GMT -5. The time now is 7:43 AM.
Previous Next