« first day (4496 days earlier)      last day (672 days later) » 

03:04
Thinking: In WPF, is there some way to binding a INotify instance to another INotify instance...?
Instance A: DataRowView, instance B: INotify instance.
What I want: Binding the property of B to field of A, twoway.
 
5 hours later…
07:50
Hi every one , I have a weird bug on Fr culture and double parse on W11 and .net Framework.
https://dotnetfiddle.net/cAQ1fc , does the following give you "?" on number group separator on W11?
like https://imgur.com/a/fWM4f0m
With .net 6 it's fine but framework and w11. gave me the hard task to rewrite every number parsing in the application.
I'm trying to build mre for an So Question but anything culture related have to be really clear or I will be kick with "change your culture/separator" when same code doenst behave the same on w10 et w11 ^^
good morning
@Mr.Squirrel.Downy mutual reference to each other, and call the implemented NotifyPropertyChanged on each other
I did something like that in WinForms. WinForms' PropertyChanged NotificationSource didn't really trigger for each keystroke, so I called PropertyChanged while listening to the DataContext's PropertyChanged event. Basically setting the values to what are they, but that triggered the prop changed too. No need to LostFocus
it set the PropertyChanged value to itself with reflection
08:08
uh....
It's a way
@DragandDrop "?" sometime means "I CANNOT DISPLAY THIS CHARACTER".
Yeah but fr culture sould be consitent and be displayed the same in 4.8 and .net 6 in w11.
Basically every w11 users can't use the app cause parsing number is something it has bee doing for 9 years now ^^
how about other .net version?
Every framework goes boom. we just manage to migrate out of 4.6.1. going to .net 6 will be harder as cristal report is not compatible with it.
uh... about crystal report, check what the function you need, and find a better alternative.
and about the output string, try output it as a text file and use some powerful editor to check the output character
@Mr.Squirrel.Downy , We will build a serveur with the report we have and deploy it in 4.8. will less effort. But for now, I have to explain why customer have to re install w10 .;). Or deals with number lesser than 999
08:23
the output give me a white space(u20), is it correct?
@DragandDrop hey
yes it should be u20. With 4.8?
Does `
var st = 24000m.ToString("c");
st = st.Replace(CultureInfo.CurrentCulture.NumberFormat.CurrencySymbol.FirstOrDefault(), '');
var result = Double.Parse(st);
var test = Convert.ToDouble(st);

Console.WriteLine(st+" " + result + " " + test);` goes boom?
output the NumberGroupSeparator in win11 into a file and check the file content, this "?" character is u3F or not.
@DragandDrop hexed.it try use this
sure give me 1min
@Mr.Squirrel.Downy , got E280 ..
Meeting i one hour got to pack every log I have thanks for your help.
08:53
Good morning
09:11
Good afternoon
@DragandDrop what the hell...
09:29
Space is private, It's called private space. So it make sense..
 
3 hours later…
12:34
, btw could you give me more information about your system?
Was it a win 10 you upgraded or a fresh install? And what culture are you on?
12:48
[Captain Obvious] uhoh why are we using private unicode characters
12:58
 using (Stream str = new FileStream(FilePath, FileMode.Open))
            {
                XElement xe0 = XElement.Load(str);
                foreach (var xe1 in xe0.Descendants("Products").Elements())
                {
                    var p = new Products
                    {
                        SysId = xe1.Attribute("Sys_Oid").Value,
                        Mainproduct = xe1.Name.ToString(),
                        Name = xe1.Attribute("Name").Value,
                        Visible = xe1.Descendants("ProductVisibility").FirstOrDefault().Attribute("Visible").Value,
Hi Gyys, morning:
Price, From & servicefee are lsit property, so how can i add the values to these list properties? thanks
[Captain Obvious] List.Add(value)
@Botler thanks, its already there, thanks; As products.add(p);
@Botler I'm having issues with Price, From & ServiceFee properties
 private List<string> from = new List<string>();
        public List<string> From
        {
            get { return from; }
            set { from = value; }
        }

        private List<string> price = new List<string>();
        public List<string> Price
        {
            get { return price; }
            set { price = value; }
        }

        private List<string> servicefee = new List<string>();
        public List<string> ServiceFee
        {
            get { return servicefee; }
13:14
[Captain Obvious] why are they lists lmao
[Captain Obvious] You can't have a list in an attribute
[Hector] hello
[Hector] how's february treating you
@Botler oh i see.. in this case i have to write another class?
[Captain Obvious] It's my birthday at least
[Hector] happy birthday!
@Botler Happy bithday!!!
@Botler , all our customer semms to be using this private char, instead of space as group separator. On their fresh Win11 install.
[Hector] I gotta convince my architect to start using secrets and zero-knowledge password checks
[Hector] these people want me to type my AD password on a plain text file
[Hector] and we're beyond the point where they'd be happy to hear I caught their phishing attempt to enroll me in some security training
[Captain Obvious] 👏 NEW 👏 JOB 👏 TIME 👏
[Hector] nah man, I am progressively getting hand on the wheel here. Contrary to other jobs I've had, I'm thriving here
[Hector] already got a bonus and a raise in less than a year
[Hector] besides, every job offer sucks hard compared to this
[Hector] all the offers I've had this far want me to do a whole department's job for a 30% lower salary and enforce presential office work, or at most, 2 day wfh
[Captain Obvious] You should come work for pwc
[Captain Obvious] Guaranteed wfh
[Captain Obvious] plenty of other people to do other jobs
[Captain Obvious] It All Part Of The New Equation™
[Hector] sold me out on the TM part
[Captain Obvious] Or wait no
[Captain Obvious] Maybe it's The Deal™
[Hector] can't be wrong if it has TM or C
[Captain Obvious] I can't remember
[Captain Obvious] The Deal™ is part of The New Equation™, okay
[Hector] xD
13:51
[ntohl (MR.TaNk)] happy birthday
14:03
Hello all,
anyone knows a mapping library that can configure types within a namespace..

For example, in AutoMapper, I want to create a map from Src to Dest
but there is another Dest class that resides in a different namespace.
it seems that I need to create a duplicate map to map from Src to Dest in the second namespace,
is there a way to tell AutoMapper to map all "Dest" in namespace "N1" and "N2" from "Src" in namespaces "N3" and "N4" (if it's coming from N3 then map to N1 type.. and so on),
14:23
[Hector] I've noticed you have a lot of problems with AutoMapper
[Hector] every time I see your name it's an Automapper issue. IDK what that tool is but maybe you should try to figure out a different one to do stuff
[Hector] unless you're just doing as you're told
AutoMapper is a tool to automagically convert an instance of one class to another by reflection
something similar can be achieved by JObject.FromObject<T1>(myObject).ToObject<T2>()
I can also recommend not using automapper (or anything else) but instead just mapping it yourself
@Botler Ah then my guess was right, I posted this same question here and forgot, never mind, seems like impossible with AutoMapper
AutoMapper will move your compiler errors to runtime errors and simple solutions to weird magical features of a non-feature complete framework
From the quick presentation I saw of the tool Mapster has a ForAllTypesInNamespace. and can have customise dotnet mapster model you may be able to craft what you need with that
[Hector] can you give an example where this may be useful?
[Hector] if you want to covert one type to another, why not cast?
[Hector] unless you have a super hole in your design, you should have both types sharing a parent or an interface
14:31
We integrate with external providers
14:46
dynamic all the way. (joke)
foreach (var xe1 in xe0.Descendants("Products").Elements())
{
	List<string> price = new List<string>();
	List<string> from = new List<string>();
	List<string> service = new List<string>();
	foreach (var xe2 in xe0.Descendants("ProductPrice"))
	{

		from.Add(xe2.Attribute("FromQuantity").Value);
		price.Add(xe2.Attribute("Price").Value);
		service.Add(xe2.Attribute("ServiceFee").Value);
	}


	var p = new Products
	{
		SysId = xe1.Attribute("Sys_Oid").Value,
		Mainproduct = xe1.Name.ToString(),
		Name = xe1.Attribute("Name").Value,
HI guys, from the above i'm not getting any values for Price, From & servicefee. What is the issue?
System.Collections.Generic.List`1[System.String], how can i fix it with foreach or something else? thanks
15:00
[Captain Obvious] Like I said before
[Captain Obvious] You cant get a list of values from an attribute
@Botler Ok, then how can i get the list? i can read the first valeu by xe1.Descendants("ProductPrice").FirstOrDefault().Attribute("FromQuantity").Value but how can i get the list i have more than 1 values in the xml file.
[Captain Obvious] You definitely don't have multiple values in the attribute
<Prices ImportStrategy="Replace">
<ProductPrice Sys_Oid="e619a334-be90-400c-9d75-f5d75cd4a9c2" Sys_GlobalUniqueId="e619a334-be90-400c-9d75-f5d75cd4a9c2" Sys_ReplicationId="6fe7ea5d-36e1-48ce-b972-861712b92e59" Sys_Type="Library.Domain.ProductPrice" FixFee="0" ServiceFee="0" Mode="Replace" FromQuantity="1" Price="0" ProductPriceType="PerPageQuantity" ReplicationId="6fe7ea5d-36e1-48ce-b972-861712b92e59" />
<ProductPrice Sys_Oid="190b26ad-baf9-4b8a-a4b6-981dc6606a58" Sys_GlobalUniqueId="190b26ad-baf9-4b8a-a4b6-981dc6606a58" Sys_ReplicationId="0ef946d5-ec66-4b73-9965-cbbffa6b0085" Sys_Type="Lib
[Hector] show us a formatted example xml
<Prices ImportStrategy="Replace">
<ProductPrice Sys_Oid="e619a334-be90-400c-9d75-f5d75cd4a9c2" Sys_GlobalUniqueId="e619a334-be90-400c-9d75-f5d75cd4a9c2" Sys_ReplicationId="6fe7ea5d-36e1-48ce-b972-861712b92e59" Sys_Type="Library.Domain.ProductPrice" FixFee="0" ServiceFee="0" Mode="Replace" FromQuantity="1" Price="0" ProductPriceType="PerPageQuantity" ReplicationId="6fe7ea5d-36e1-48ce-b972-861712b92e59" />
<ProductPrice Sys_Oid="190b26ad-baf9-4b8a-a4b6-981dc6606a58" Sys_GlobalUniqueId="190b26ad-baf9-4b8a-a4b6-981dc6606a58" Sys_ReplicationId="0ef946d5-ec66-4b73-9965-cbbffa6b0085" Sys_Type="Lib
15:05
[Hector] let me check on c# chat
[Hector] because i dont see this formatted at all
[Hector] yeah it wasn't just me
[Hector] i mean botler kinda enjoys cutting off at whatever character limit it has for its messages but it's not formatted either
[Hector] maybe reduce it to have like 3-4 items and format it properly
[Hector] i believe the shortcut was ctrl k
<ProductVisibility Sys_Oid="90f6ec6d-0536-4328-b74b-78ca62556ef4" Sys_GlobalUniqueId="90f6ec6d-0536-4328-b74b-78ca62556ef4" Sys_ReplicationId="6de65cf7-ed21-4116-bd7c-7befc2134a10" Sys_Type="Library.Domain.ProductVisibility" Activated="True" OverrideServerProductPrices="False" PhotoSource="EndUserPhotos" BackgroundColor="Default" Icon="" Image="" IsUnusableByLicense="False" MaxDate="2999-12-31" MinDate="1900-01-01" Name="" OrderableObjectVisibility="Visible" Visible="True" ProductLibrary="DEFAULT" ReplicationId="6de65cf7-ed21-4116-bd7c-7befc2134a10" SysCode="">
i jsut selected all and pressed ctrk+k
[Hector] wait that's the formatted version? let me try
```XML
<root>
<test1></test1>
<test1></test1>
<test1></test1>
<test1></test1>
</root>
```
[Hector] c# chat is ass
@HéctorÁlvarez How?
15:14
[Hector] I mean the SO verison
Sorry guys i couldnt share the file, i jsut posted the image format
15:29
[Hector] i think the bot didn't work there
[Hector] !check
[Hector] it's back
[Hector] IDK what you're trying to do exactly
[Hector] if you can elaborate an example that's readable, I'll try to help
I'm trying to read the xml file and get the contents loaded to the datagrid view, a product contains tier pricing so i need to get the list of tier pricing for a product and display it in the gridview.
@Botler I dont know if the above explanation is good enough to understand. As i said before i know how to get the firstvalue as xe1.Descendants("ProductPrice").FirstOrDefault().Attribute("Price").Value, my issue to get Tier Pricing/multiple price values as list.
Ryan Donovan on February 03, 2023
We chat with Dr. Jeannette (Jamie) Garcia, Senior Research Manager of Quantum Applications and Software at IBM Quantum about their 433 qubit quantum computer and what the real life applications of quantum computing are today. 
[Hector] I know what you want to achieve, but since there's no readable XML it's not really that viable to come up with a solution
How can i share the file?
[Hector] I mean, in general, people will probably help if you make a reasonable explanation instead of copy pasting a massive file and expect someone else to do the work for you
[Hector] it's not a matter of sharing the file, but in any case, if you're in SO chat there's usually some text at the top right to paste large pieces of text
[Hector] but I'm certain nobody is going to read through a big xml
15:43
Sorry about the inconveniences; i just shared the file via AWS link.
[Hector] I also doubt people would click a random link
@Botler lol,
[Hector] it's a matter of presenting the problem in a comprehensible way
[Hector] remember everyone here's doing their stuff, they'll help if there's something they can help with, but nobody's going to sit through a 15 minute read if that takes their attention away from their work
@Botler Roger that. I'll pay attention and noted your feedback.
Hi Guys is there a way to bind the HtmlAttributes to a model?
meaning can I do something like this
.HtmlAttributes(@item.isRequired ? new { required = 'required', data_val_required = 'Question is Required' } : null)
.HtmlAttributes(item.htmlAttributesData)
both are not working for me
 
2 hours later…
18:24
posted on February 06, 2023 by Kathleen Dollard

Interested in what is going on and the future of .NET languages, (C#, F#, and Visual Basic)? We have just published an updated version of the .NET Language Strategy on our documentation! The post Update to the .NET language strategy appeared first on .NET Blog.

 
4 hours later…
22:02
@Jefferson Need some more information. Which framework? MVC? Blazor? WinForms (why would you need html then but who knows)? Are you in a Razor Component?
22:18

« first day (4496 days earlier)      last day (672 days later) »