|
hi
I will open the word file with C#2005 but print content file with c#2005
please help meeeeeeeeeee
tanks a lot
|
|
|
|
|
|
hi there,
i insert binding navigator and bind it to combobox items like this
BindingSource bindingSource = new BindingSource();
bindingSource.DataSource = combobox.Items;
bindingNavigator1.BindingSource = bindingSource;
and its working but it have a problem that when i select any item in combobox then its position dont increase.
to do that i tried to just assign the "selectedindex + 1" of combobox to its position textbox's text in SelectedIndexChanged event
and its shows correct position but its not actual, that mean it just showing, not working
for example
i have 3 items in combobox, and i select 3rd item then it will show position is 3 but the last and next buttons still enabled and first and previous still disabled.
any idea to solve it?
thanks
Becoming Programmer...
|
|
|
|
|
Have you tried the Refresh method?
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
yeah, but it didnt work
Becoming Programmer...
|
|
|
|
|
|
Downloaded it and looks pretty cool.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Hello,
I have been trying to render an SVG file on a form, but I can't seem to get it right. The main thing I need is to get SVG files onto the main form, and the possibility to scale them without loss of quality. I have been trying some things with Svg.Net, but to no avail.
Maybe I am missing a really obvious thing, but I would sure appreciate it if someone could give me some pointers.
Thanks in advance!
Kind regards,
Johnny
|
|
|
|
|
The really obvious thing to me would be to put a browser control in your form and let it render the SVG ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Thanks, that would be a good idea, but we need to render and scale icons for Points Of Interest for a route navigation application ourselves. We also need to scale those icons dynamically. Drawing the map is done in a PictureBox, so a browser control is really not an option.
|
|
|
|
|
Hi All,
I wanted to share this with anyone who may stumble across this thread.
X.690 specifies a BMP string is the 2-octet canonical form (specified in ISO/IEC 10646-1) [1] of UCS (also specified in ISO/IEC 10646-1) [2]. Note that ASN.1 does not include an "Endianness" marker in its octet stream [3].
ISO 10646 prefers Big Endianness, though it is not standardized [4]. According to Microsoft, CodePage 1200 is Unicode (UTF-16), and CodePage 1201 is Unicode Big Endian (16 bits also)[5].
In memory, the byte[] from the ASN.1 sequence is [00 77 00 105 00 99 00 114 00 111 00 115 00 111 00 102 00 116 ...]. This is a Big Endian Serialization [6] from Microsoft's Cryptograhic Service Provider.
When interpreted as Unicode, I receive a non printable string. When interpreted as Big Endian Unicode (CodePage 1201), I receive 'Microsoft'.
So, a test of byte[] (Value[0]) is required to properly return the string. The return will be either Encoding.GetEncoding(1200).GetString(Value); or Encoding.GetEncoding(1201).GetString(Value).
Simply using Encoding.Unicode does not produce expected results in every case, since Unicode implies Little Endianness when using C#.
Jeff
[1] ITU X.690, p. 16, Section 8.21.8
[2] ITU X.690, p. 16, Section 8.21.9
[3] ITU X.690, p. 16, Section 8.21.9. Note 2b.
[4] ISO-10646, Section 6.3
[5] EncodingInfo Class[^]
[6] RFC 2781, Section 3.1
|
|
|
|
|
I'm trying to follow a guide in a book. It tells me this line:
wave = new DirectSound.SecondaryBuffer("laser1.wav", sound);
and gives me several more lines. Yet I try this and more wave files and I keep getting the same error.
SoundException was Unhandled
What do I do to make this work, because, I QUOTE from the book, "this is amazingly simple". Thanks in advance.
- I love D-flat!
|
|
|
|
|
You might want to try specifying the fully qualified filespec (this is always a good idea) instead of simply laser1.wav . It's also a good idea to catch possible exceptions, eg:
try {
wave = new DirectSound.SecondaryBuffer("C:\\laser1.wav", sound);
}
catch (SoundException ex) {
}
/ravi
|
|
|
|
|
Could it be a wrong version of DirectSound? Here's the full code.
(one line above...)
private void PlaySound()<br />
{<br />
DirectSound.Device Sound;<br />
DirectSound.SecondaryBuffer Wave;<br />
DirectSound.BufferDescription Description = new DirectSound.BufferDescription();<br />
Description.ControlEffects = true;<br />
<br />
Sound = new DirectSound.Device();<br />
Sound.SetCooperativeLevel(this, CooperativeLevel.Priority);<br />
Wave = new SecondaryBuffer("song1.wav", Description, Sound);<br />
Wave.Play(0, BufferPlayFlags.Default);<br />
}
- I love D-flat!
|
|
|
|
|
MasterSharp wrote: Could it be a wrong version of DirectSound?
What's the message of the exception you caught?
/ravi
|
|
|
|
|
That's also what it gives me in the book. I probably shouldn't deviate too much.
- I love D-flat!
|
|
|
|
|
MasterSharp wrote: That's also what it gives me in the book. I probably shouldn't deviate too much.
Sorry, I don't understand what you're saying. What is "that"?
/ravi
|
|
|
|
|
"laser1.wav" I don't know what to do, and I;m also trying articles on the net too.
- I love D-flat!
|
|
|
|
|
MasterSharp wrote: I don't know what to do,
Well for one you could try what I suggested doing. See my first reply in case you've forgotten.
/ravi
|
|
|
|
|
What does that do? Or how would I do what you're suggesting. I really don't know C#, my friend.
- I love D-flat!
|
|
|
|
|
MasterSharp wrote: What does that do?
Specifiying a fully qualified filespec guarantees that your code will attempt to operate on a file that exists.
MasterSharp wrote: how would I do what you're suggesting.
Edit the code and recompile and re-run your program.
/ravi
|
|
|
|
|
I'm sorry that I'm pushing my help and all, but what would I do in the catch part, to find out? I added the code, except for that.
- I love D-flat!
|
|
|
|
|
I tried it without code in catch, and it doesn't stop the program and give me an error, but I don't hear sound.
- I love D-flat!
|
|
|
|
|
I got the error code from "ex". 2147287038
- I love D-flat!
|
|
|
|
|
MasterSharp wrote: it doesn't stop the program and give me an error
That's probably because you're "eating" the exception (i.e. catching it but not doing anything about the fact that an exception was thrown).
/ravi
|
|
|
|