mam taky problem. robim program a neviem ako mam spravit aby sa my neukazoval v tom modrom panely(tam kde je start) kde su zobrazovane programy ale by sa mu zobrazovala ikona v pravo dole ako je napr. skype ale aby sa nedal vypnut ked kliknem na X v okne. dik za rady
Fórum › .NET
Ikona v dolnej liste

Prestuduj si MSDN k teme NotifyIcon, Form.Visible, Form.Hide(), Form.Show(), MenuStrip,...
http://msdn.microsoft.com
A nebud lenivy! Takto sa nenaucis programovat...
dik. aa este ako mam spravit aby sa subor napr. lol.xcv otvaral v tom programe a mal nejaku ikonu? skusal som toto ale neda sa zaregistrovat ta pripona suboru a neni to robene aby tam bola ta ikona:
private void associateFiles()
{
try
{
RegistryKey registryKey1 = Registry.ClassesRoot.OpenSubKey(".xcv");
string string1 = registryKey1.GetValue("").ToString();
if (((registryKey1 != null) && (string1 != "xcv file")) && (MessageBox.Show("Associate cakePawn with Pawn (.xcv) files?", "File Associations", MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button1) != System.Windows.Forms.DialogResult.Yes))
{
return;
}
registryKey1 = Registry.ClassesRoot.CreateSubKey(".xcv");
registryKey1.SetValue("", "xcv subor");
registryKey1 = Registry.ClassesRoot.CreateSubKey("xcv subor");
registryKey1 = registryKey1.CreateSubKey("shell");
registryKey1 = registryKey1.CreateSubKey("open");
registryKey1 = registryKey1.CreateSubKey("command");
registryKey1.SetValue("", string.Format("\"{0}\" \"%1\"", typeof(Form).Assembly.Location));
registryKey1 = Registry.ClassesRoot.CreateSubKey("MIME\\Database\\Content Type");
RegistryKey registryKey2 = registryKey1.CreateSubKey("application/cakepawn");
registryKey2.SetValue("Extension", ".xcv");
MessageBox.Show("Successfully registered files.");
}
catch
{
MessageBox.Show("Nedá sa zaregistrovať tato pripona suborov.");
}
For instance, here's a sample registry file to create an association between .txt files and EmEditor:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\.txt]
@="emeditor.txt"
[HKEY_CLASSES_ROOT\emeditor.txt]
@="Text Document"
[HKEY_CLASSES_ROOT\emeditor.txt\DefaultIcon]
@="%SystemRoot%\\SysWow64\\imageres.dll,-102"
[HKEY_CLASSES_ROOT\emeditor.txt\shell]
[HKEY_CLASSES_ROOT\emeditor.txt\shell\open]
[HKEY_CLASSES_ROOT\emeditor.txt\shell\open\command]
@="\"C:\\Program Files\\EmEditor\\EMEDITOR.EXE\" \"%1\""
[HKEY_CLASSES_ROOT\emeditor.txt\shell\print]
[HKEY_CLASSES_ROOT\emeditor.txt\shell\print\command]
@="\"C:\\Program Files\\EmEditor\\EMEDITOR.EXE\" /p \"%1\""
lolik: si vytvoris v HKEY_CLASSES_ROOT\.xcv kluc a nastavis defaultnu hodnotu na napr "xcv.Program", potom si vytvoris kluc HKEY_CLASSES_ROOT\xcv.Program\DefaultIcon, defaultna hodnota ikona (alebo DLL s ikonami), potom kluc HKEY_CLASSES_ROOT\xcv.Program\shell\open\command, defaultna hodnota cesta k tvojmu programu + "%1". Vsetko programovo.
K práci s registry slouží třída Registry z namespacu System.Win32. To už najdeš snadno.

Přidej příspěvek
Ano, opravdu chci reagovat → zobrazí formulář pro přidání příspěvku
×Vložení zdrojáku
×Vložení obrázku
×Vložení videa
































Uživatelé prohlížející si toto vlákno
Podobná vlákna
Jak udělat v liště nabídku — založil dragon124
Volba Fórum i dole na liště — založil hlucheucho
Vytvoření více formulářů a jejich viditelnost ve spodni liště — založil Remder
Moderátoři diskuze