✅ Windows Forms Problem
I have a Problem it only shows "<" then the COmputer name but nothing else
```cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Defraint
{
public partial class Form1 : Form
{
int positionX = 219;
int positionY = 9;
public Form1()
{
InitializeComponent();
}
private void SendButton_Click(object sender, EventArgs e)
{
string message = MsgBox.Text;
string labelText = "<" + Environment.MachineName + "> " + message;
Label newLabel = new Label();
newLabel.Text = labelText;
newLabel.Location = new System.Drawing.Point(positionX, positionY);
positionY += 25;
newLabel.ForeColor = Color.White;
newLabel.Font = new Font("Calibri", 16);
this.Controls.Add(newLabel);
}
}
}
5 Replies
When i leave the Environment.MachineName out it works
$codegif
Have you tried stepping through the code or use the immediate window to debug?
Any exceptions?
Unknown User•8mo ago
Message Not Public
Sign In & Join Server To View