C
C#2y ago
itgel9462

❔ Display string that divided 1 by 1 word in textbox.

I tried to display string sentence 1 by 1 word in textbox. I used string.split() method to split. But in textbox the string did not get split,which means the sentence is displayed as it was. How can I display?
11 Replies
Buddy
Buddy2y ago
$details
MODiX
MODiX2y ago
When you ask a question, make sure you include as much detail as possible. Such as code, the issue you are facing, and what you expect the result to be. Upload code here https://paste.mod.gg/ (see $code for more information on how to paste your code)
itgel9462
itgel94622y ago
I'm trying to create this reading technique spritz. I created a frame in XAML and in this method I'm calling the frame. String is just for example (japanese though). x_coordinate.Text represents text that will display in the frame.
itgel9462
itgel94622y ago
is that clear I used split() method to split a sentence 1 by 1 word and tried to display them in the frame.
Buddy
Buddy2y ago
Do you want to split text then join the array of strings by , ? That will result in something like this hello world foo bar will turn to hello,world,foo,bar
CrumpetMan
CrumpetMan2y ago
string.ToCharArray() then join them.
itgel9462
itgel94622y ago
This method only does comma split? I didn’t know that sorry. I thought that is the way to divide the text. Should I use other method to make this Spritz frame?
CrumpetMan
CrumpetMan2y ago
Divide the text how? You want to make an array that contains each word found in a string Then split them by a comma?
Buddy
Buddy2y ago
string.Join(",", arr) joins an array separated by a comma into a string. Which will turn to what I mentioned above.
itgel9462
itgel94622y ago
What I thought is like divide by comma first, and if the comma comes out in the frame, just remove the comma and the word before it. Then pick up the next word and it continues. Main task is create that Spritz frame. To make it, I thought I had to divide words 1 by 1 by using string.split(). I'm sorry for my bad explanation . Now what I want to ask is, Is this way possible to do? Or is there some method that more useful for my task? What do you guys think
Accord
Accord2y ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server
More Posts
❔ Will there be issues if the target framework moniker is less than my .NET version installed?Total scrub here, please correct if I say anything wrong. I've got Visual Studio installed with .NET❔ Singleton Pattern StackOverflowExceptionIn the attached code, the GameManager is working fine, but InputManager is throwing a StackOverflowEGet the first letters of a stringHello, Let's say that I have the string "tyranitar". With string[X], I can get the letter that I wa❔ I cant find the Option "ConsoleApp" when creating a new projektI also installed the .NET thing but i cant choose it, one screenshot is from a tut and other one sho❔ hello, Im new in C# codding, could someone help me ? I think something is wrong in my code :(Restoring my source codeHello, I have built a simple C# app, and i debugged it and only got the .config, .exe and .pdb files❔ Callback Url Always NullHere's the two functions involved ``` public IActionResult ExternalLogin(string provider, str❔ Game telemetry & overlay project - help with framework & architecture decisionstl;dr I want to create an application which continuously reads telemetry data from a racing game anderror CS0176: Member 'DateTime.Now' cannot be accessed with an instance reference; qualify it with aHi, i'm a beginner and i come from JavaScript and python. I'm having an issue with my CSharp code: `❔ Dapper - Call stored procedure errorI finished to write my first POST Api, but I get an error when I execute it and it call a stored pro