SAFE
Cant find design view for win form
I installed visual studio 2022 on new laptop. I cant find design view anymore. Before it would usually start up the form file as form but now it wont. I have tried things like shift f7, right clicking my file(but there is no option to view as design when i right click), I have also trierd changing web forms designer setting to start in design view, If anyone could help me would be great
23 replies
❔ Help with Lists/Combobox
public partial class Form1 : Form
{
const decimal SALES_TAX_RATE = 0.15m;
// private List<Order> orders = new List<Order>(){"Potatos"};
// string[] genres = { "Blues", "Country", "Hip Hop", "Easy Listening", "Rock", "Pop" };
// List<Order> order = new List<Order>(genres);
string[] genres = { "Blues", "Country", "Hip Hop", "Easy Listening", "Rock", "Pop" };
List<Order> orders = new List<Order>();
public Form1()
{
InitializeComponent();
}
//string[] genres = new string[]
// {
// "Blues",
// "Country",
// "Easy Listening",
/// "Hip Hop",
// "Rock",
// "Pop"
// };
#region Methods
private void ResetForm()
{
cboGenres.SelectedIndex = -1;
txtAlbumName.Text = "";
txtArtistName.Text = "";
txtQuantity.Text = "";
txtPrice.Text = "";
txtArtistName.Focus();
}
public void LoadGenres()
{
for (int i = 0; i < genres.Length; i++)
{
cboGenres.Items.Add(genres[i]);
}
}
private void Form1_Load(object sender, EventArgs e)
{
LoadGenres();
}
49 replies
✅ while loop help(im new ish so its probs obvious)
'''cs
namespace HippityHop
{
internal class Program
{
static void Main(string[] args)
{
Console.WriteLine("** HIPPITY HOP **");
Console.Write("Please enter an integer between 1 and 100:");
// WRITE YOUR CODE BELOW THIS COMMENT
string input = Console.ReadLine();
int num = Convert.ToInt32(input);
while (num <= 100 || num >= 1)
{
Console.Write("Please enter an integer between 1 and 100:");
num++;
return;
}
for ( num = 1; num == num; num++ )
{
if(num % 3 ==0)
{
Console.WriteLine("Hip");
}
if (num % 5 == 0)
{
Console.WriteLine("Hop");
}
if (num % 5 == 0 && num % 3 == 0)
{
Console.WriteLine("Hop");
}
}
}
}
}
'''
114 replies