|
Attend an upcoming MSDN Developer Conference [^]and you will receive a Windows 7 Beta 1 DVD either at the event or mailed to you (depending on Windows 7 Beta release date).
Register today [^]and you’ll get the best of the PDC in your own backyard and hear all of the exciting announcements around the Azure Services Platform and Windows 7. The day-long conference is held in Houston TX, Orlando FL, Atlanta GA, Chicago IL, Minneapolis MN, Washington DC, New York NY, Boston MA, Detroit MI, Dallas TX, and San Francisco CA between December 9 and February 19.
- Experience Windows Azure. Create applications that seamlessly bridge the gaps between PC, Web, and phone
- Be among the first to see Windows 7. See the latest advances in Multi-Touch Application Development.
- Take your .NET skills to the next level. See sessions on WPF 4.0, Silverlight 2, The Future of C# and VB, ASP.NET 4.0, Live Mesh and more
Check out the sessions here[^]. Cost is $99.
|
|
|
|
|
Hi,
I wrote an application that able to connect another bluetooth device in .Net Framework 2.0 using bluetooth API, now I want to do this with .Net Compact Framework on my mobile device. That's the problem, When I'm Calling Bluetooth API like WSAStartup or using SizeOf method of Marshal class, it gives me NotSupportedException exception.
Please tell me how can i solve this problem.
Thank you.
DMASTER
|
|
|
|
|
You're going to have to rewrite the code to do whatever it is you want a different way, since, well, what you're doing now is NotSupported on .NET CF.
BTW: You might want to post future queries to this problem in the Mobile Development Forum.
|
|
|
|
|
Thanks for your reply dear Dave.
But I hadn't rewrite my previous code in .net compact framework, I know all methods and parameters that should be set on .net compact framework. Ok, Lets suppose that you are right, so what about SizeOf Method . If you refer to msdn, you can see that, it's marked as supported on .net CF.
Thank you.
|
|
|
|
|
You never showed the code and line where the exception occured, so it's impossible to say anything else.
|
|
|
|
|
I am creating n pictureboxes and then setting a different image on each one of them in a loop. The user clicks on open n opens a .zip file (containing images only). I am unzipping the .zip contents in a folder and am able to extract the images from there.For the first time the pictureboxes rightly shows the images. But when again user click on the open button and select a .zip file to be opened. The new images doesnt appear completely.
Problem could be: previous images are not getting removed so are not allowing the new images to appear.
Language: c#
code:
pb = new PictureBox[r*c];
Point point = new Point(100, 100);
for (i = 0; i < r * c; i++)
{
pb[i] = new PictureBox();
{
pb[i].Dispose();
}
pb[i].Image = null;
}
int w = 800 / r;
int k = 0;
int h = 700 / c;
int a = w, b = h;
for (i1 = 0; i1 < r; i1++)
{
b = 15;
for (i2 = 0; i2 < c; i2++)
{
pb[k] = new PictureBox();
pb[k].Image = null;
pb[k].Size = new Size(w, h);
this.Controls.Add(pb[k]);
if (i1 == 0 )
{
pb[k].Location = new Point(10, b);
}
else
{
pb[k].Location = new Point(a, b);
}
b = b + h;
Bitmap img=new Bitmap("d:\\puzzlesolver\\pieces\\piece"+i2.ToString()+i1.ToString()+".png");
Bitmap img1 = new Bitmap(img);
pb[k].Image = img1;
pb[k].SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
pb[k++].Update();
this.Update();
}
a = a + w;
}
this.Update();
I have tried a lot of things please tell me how to remove the existing picture boxes which are dynamically allocated and then add them again. I hope m clear!!
|
|
|
|
|
heyy, please reply to this question guys................
|
|
|
|
|
You should not push people to reply to your question. Either the person who knows what is the problem hasn't seen it yet, or nobody knows. Exercise a little patience.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
for (i = 0; i < r * c; i++)
{
pb[i] = new PictureBox();
{
pb[i].Dispose();
}
pb[i].Image = null;
}
This is almost certainly not doing what you expect. You are creating new PictureBoxes and immediately Disposing them.
this.Controls.Add(pb[k]);
Every control added to a Form stay on the form until you call this.Controls.Remove with the same control. Disposing the control before removing it from the form may cause an exception, so make sure you do it in the right order.
|
|
|
|
|
Thnk you for replying..... i was successfully able to handle the problem that i was facing
|
|
|
|
|
Hi to all,
I have a third parity DLL that I need to use.
I have some examples written in VB6 and C++
I tried to convert a function declaration from VB6 to VB.NET
My conversion doesn't works correctly.
Problem specifications
1. In the DLL there are 2 function called "EupicdsmGetFlashInfo" and "EupicdsmGetFlashInfoW"
2. The c++ declarations are:
EUPICDSM_LINK int __stdcall EupicdsmGetFlashInfo(
const int index,
int& numDrives,
char* drives,
int& drives_len,
char* serial,
int& serial_len);
Vendor specifications:
drives [out]
Pointer to char that receives the list of drive letters associated to the device. The drive letters have SCSI
format ( \\.\H: ) and they are separated by the terminating null character (ASCII code 0). A double terminating
null character is the end of list. If this parameter is NULL, function returns EUPICDSM_ERROR_PARAM_LEN
and iDriversLen receives the minimum size for containing the entire list.
EUPICDSM_LINK int __stdcall EupicdsmGetFlashInfoW(
const int index,
int& numDrives,
BSTR* pDrives,
BSTR* pSerial);
Vendor specifications:
pDrives [out]
Pointer to wide character string that receives the list of drive letters associated to the device. The drive
letters have SCSI format ( \\.\H: ) and they are separated by the terminating null character (ASCII code 0). A
double terminating null character is the end of list.
3. The VB6 declarations are:
EupicdsmGetFlashInfo - NOT DECLARED in the example !
Declare Function EupicdsmGetFlashInfoW Lib "eupicdsm.dll" (
ByVal iIndex As Long,
ByRef iNumDrives As Long,
ByRef pDrives As String,
ByRef pSN As String) As Long
4. My VB.NET conversion:
Declare Function EupicdsmGetFlashInfo Lib "eupicdsm.dll" (
ByRef index As Long,
ByRef numDrives As Long,
ByRef drives() As Byte,
ByRef drives_len As Long,
ByRef serial() As Byte,
ByRef serial_len As Long) As PD_RETURNVALUES
Declare Function EupicdsmGetFlashInfoW Lib "eupicdsm.dll" (
ByRef iIndex As Long,
ByRef iNumDrives As Long,
ByRef pDrives As String,
ByRef pSN As String) As PD_RETURNVALUES
Problem:
The result of function EupicdsmGetFlashInfoW (as declared at point 4.) is wrong:
only the name of the first driver (even if there are more ex. 2 or 3) is returned in the pDrives String.
I suppose the trouble may be in the use of null character (ASCII code 0) as separator.
So I tried to use the "EupicdsmGetFlashInfo" but it gives an error.
Is there someone who can halp me?
how can I change the declaration? is it better to use "EupicdsmGetFlashInfo"?
thanks in advance
Bye
Boris
|
|
|
|
|
Am Developing an windows application in .NET 2.0 Framework.
The scenario is like,
In User interface,
We have textbox's for username & another for password.
The user will enter username & then he press enter key, after pressing enter key the cursor must come to password textbox, can any please solve the problem.
Am unable 2 study abt the ENTER key, generally V can have through by pressing tab key,
but client request is only throught enter key......
Thank you in advance...
Hope u people will b solving it...
|
|
|
|
|
You need to handle the keydown or keypressed event on the text box. In this event handler, you can check what key was pressed. If the enter key was pressed, you can set focus to the next control by calling .Focus() on the control.
Simon
|
|
|
|
|
look for the key pressed is e.keycode==13 .... for enter key
then txtpassword.focus()
thanks
Tony
|
|
|
|
|
|
Well, you don't have much of a choice but to process all deletes first, then go through and add the rows. The TableAdapter goes through the rows, one-by-one and processes them according to their state. If, by chance, you've added a row to a dataset, then you've pretty much duplicated a key because the adapter hasn't gotten to the deleted row yet and executed the SQL for it. Normally, people don't reuse key values.
|
|
|
|
|
can we use WCF in an application using Frameworks .NET 2.0 without installing 3.0 version.
Imean is there any extensions to add to frameworks 2.0???
thank you for you answer
|
|
|
|
|
That's what .NET 3.0 really is. It's the .NET 2.0 CLR plus the WCF, WPF, WWF, and CardSpace extensions.
|
|
|
|
|
can use only wcf extension i mean like adding assembly or something like that. can we use wcf without installing framework 3.0
|
|
|
|
|
In theory, yes I think you can. You would have to distribute all the required 3.0 assemblies along with your app. (I haven't tried it, but I think it should work)
I'm not sure it's legal though. I don't think MS provide a redistribution license with .net You have to redistribute the full package in it's original form, you aren't permitted to break it up and distribute only the bits you want.
Why not just install .net 3.0?
Simon
|
|
|
|
|
Yeah, you have to distribute .NET 3.0. You cannot distribute just the WCF components with your app. That IS the installer for "just the components". Since .NET 2.0 is already there, you're only going to get the extensions installed.
|
|
|
|
|
I have a large .net application (.net 2.0). It runs smoothly under win 2000 and xp sp2. But it will hang under win XP SP3 and vista once it is idled for 20 minutes.
Does anyone know what is the potential problem?
Also is there any good way to find out what cause the problem under vista?
|
|
|
|
|
zhyluopro wrote: Does anyone know what is the potential problem?
Any one, or more, of about a millions things. Without knowing anything about the application or what it's doing, or what it's doing when it hangs, it's just about impossible to tell you what's going on.
You'll have to attatch the debugger to the app to see what's happening when the machine is idle.
|
|
|
|
|
Dave Kreskowiak wrote: Without knowing anything about the application or what it's doing, or what it's doing when it hangs, it's just about impossible to tell you what's going on.
He was probably expecting you to look into a crystal ball and give him the blow-by-blow details as to what the problem is
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
My crystal ball is telling me:
Deadlocks due to smaller scheduling quanta in the new kernel. Probably because some yahoo is playing around with sleep(stupidly small number).
Whooooo, spooky!
|
|
|
|
|