|
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Drawing.Imaging;
public partial class Templates_Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Bitmap myBitmap = new Bitmap("D:\\WebSite1\\image\\egy111.jpg");
Graphics g = Graphics.FromImage(myBitmap);
g.DrawString("My\nText", new Font("Tahoma", 1000), Brushes.Red, new PointF(340,500));
}
}
why this code don't work in web application
|
|
|
|
|
and don't post the same friggin' question twice, unless you want me to repeat the answer.
|
|
|
|
|
Hi Everone,
I´m looking for a implementantion or a code or even a Tip to implement one Autocomplete (intellisense) like visual studio. For example:
If you tipe DT in caps letters in visual Studio they suggest DateTime and any other item wich contains D in begining and T in the middle. in capital letter. It´s amazing, I really want to put this in a WindowsForms application.
Thanks in advance!
|
|
|
|
|
I don't know that it is possible like you specified (D******T***). But it is possible doing auto complete for Da******.
Refer this Link[^]
|
|
|
|
|
Thanks Sirama, I´m thiking here, I could try to search if the letter is upper case, like D%T%...
I will try this later, thanks.
|
|
|
|
|
private static final java.text.Collator COLLATOR = java.text.Collator.getInstance();
private static final String[] NORM_STRINGS = new String['z' - 'a' + 1];
{
COLLATOR.setStrength(Collator.PRIMARY);
for (char b = 'a'; b <= 'z'; b++)
{
NORM_STRINGS[b - 'a'] = new String(new char[] { b });
}
}
|
|
|
|
|
Repost from Java forum[^]
Please post a question in one forum.
In some cases, my signature will be longer then my message...
<em style="color:red">ProgramFOX</em> ProgramFOX
|
|
|
|
|
Hi, I have tried all sorts of help provided over the internet and couldn't manage to populate the wpf datagridcomboboxcolumn with collection of values from arraylist.
Following is my code:
XAML:
<DataGridComboBoxColumn Header="Rooms" Width="*" ItemsSource="{Binding Path=SwitchesList}" SelectedItemBinding="{Binding Path=room}" ></DataGridComboBoxColumn>
CODE BEHIND:
private ArrayList arrSwitches;
public ArrayList SwitchesList
{
get { return arrSwitches; }
set
{
arrSwitches = adb.getSwitchList(switchtype);
}
} ;
What am I doing wrong here?
Thanks in advance.
|
|
|
|
|
Member 9678427 wrote: What am I doing wrong here?
..assuming that it'll be filled, because the getter is called. It will not be initialized, unless "set". This should have been a read-only property, initialized in the constructor.
|
|
|
|
|
can you tell the code for converting speech to text using csharp .net?
|
|
|
|
|
Take your pick[^].
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
|
Hi,
I have a word file. And I am trying to modify the content of this file by using C# (via Microsoft.Office.Interop.Word).
For example: My file includes the below lines:
"Full name: ....
Address: ....
City: .... "
And, I want to change the "full name" and "city" to :
"Full name: John Markery
Address: ....
City: London"
How can I do that ?
Thanks and regards,
|
|
|
|
|
|
Thank you,
I am using it. Do you know how to remove a line (that contain a specify word) or remove a symbol (of Font: Wingdings) ?
|
|
|
|
|
Sorry no, but it's just a question of using the interop features to read and rewrite the file, while removing or changing certain information. You could try a Google search for articles on the subject.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
|
Hi all,
I have a textbox with autocomplete set to suggest.
I want to execute my code in the Textbox_KeyDown event on the enter key,
but enter key is also invoked when I select an item from the text box autocomplete items.
That is not what I want.
I want the selected item in the textbox and then execute my code.
code:
private void opdrverwTextbox_KeyDown(object sender, KeyEventArgs e)
{
if (e.KeyData == (Keys.Enter) && !string.IsNullOrEmpty(opdrverwTextbox.Text))
{
e.Handled = true;
a lot of other code........;
}
opdrverwTextbox.Clear();
opdrverwTextbox.Visible = false;
opdrverwLabel.Visible = false;
dataGridView_Update();
}
}
I don't want to set autocomplete to suggest-append.
is there a workaround for this?
Merry Christmas,
Groover
b>
0200 A9 23
0202 8D 01 80
0205 00
|
|
|
|
|
Hi all,
Found a solution myself after long google search.
It works but can someone explain how?
here is my new code:
[System.Runtime.InteropServices.DllImport("user32.dll")]
private static extern short GetKeyState(Keys key);
private void opdrverwTextbox_KeyDown(object sender, KeyEventArgs e)
{
if (e.KeyData == (Keys.Enter) && !string.IsNullOrEmpty(opdrverwTextbox.Text)&&
GetKeyState(Keys.Enter) < 0)
{
e.Handled = true;
a lot of other code........;
}
opdrverwTextbox.Clear();
opdrverwTextbox.Visible = false;
opdrverwLabel.Visible = false;
dataGridView_Update();
}
Groover,
0200 A9 23
0202 8D 01 80
0205 00
|
|
|
|
|
I am developing an c# application and
it uses many .net assemblies. For some
reason i need to move a dll to program
files folder and that dll depends on
many other assembly present in the
application folder and this makes me to copy all dependent dlls to programfiles
folder. This will cause duplication of dll
in both application and programfiles
directory. I know that moving
dependent assembly to GAC will resolve
this issue but i shound not put many assembly in GAC. So please suggest a
way to make .Net dll to reference its
dependent dlls.
|
|
|
|
|
KASR1 wrote: For some reason i need to move a dll to program files folder
No there is no reason you need to do that.
Just as many other programs do not. What they do is create a sub folder and that is where the application goes.
|
|
|
|
|
I am not sure whether i have confused.
Lets put that again, during deployment of my application i need install a particular dll to program files sub directory (eg. C:\program files\test). But my application will be in different directory. Since the dll Installed away from application directory and it uses/references many dlls present in application directory. How do i make that dll to pick dependent dlls from application directory. I dont want to move to GAC. Hope its clear.
|
|
|
|
|
Your application, let us call in it MyApp.exe will live in the following directly.
C:\program files\MyCompany
The dependent dlls will live in the same directory.
|
|
|
|
|
Lets us take an eg., I have MyApp.exe, Test1.dll,Test2.dll,Test3.dll.
MyApp.exe depends/uses Test1.dll
Test1.dll depends/uses Test2.dll, Test3.dll
If i am installing all binaries to same directory say D:\TestAppln\ then my application will work perfectly.
But due to some issues i need to move Test1.dll to programfiles sub-directory always(e.g, C:\program files\MyCompany) irrespective of installation. My application may reside in any directory.
Since Test1.dll depends on Test2.dll and Test3.dll, i need to copy them from application folder to Test1.dll's folder i'e (e.g, C:\program files\MyCompany). Otherwise Test1.dll will not load.
So my question is how to make Test1.dll to refer its dependant dll from application folder.
I am looking for options other than GAC.
|
|
|
|
|
You can load the dlls dynamically.
Also the AppDomain has an option that allows you to specify a search path.
Creating an AppDomain yourself is one option. However I believe it is also possible to set that in the application itself perhaps via one of the properties.
|
|
|
|