|
Under WinCE if you put an EXE into an AutoRun folder then it will run at startup.
|
|
|
|
|
|
There is a folder named Start programs under windows directory. You should place the executable under it.
What a curious mind needs to discover knowledge is noting else than a pin-hole.
|
|
|
|
|
Hi I have an exe and I want to start it when the device reboots so I created a short cut of it in the StartUp folder with SHCreateShortCut API .... but when my device reboots the exe doen't start its gives a certification error dialog box stating that
"The file cannot be opened .Either it is not signed with a trusted certificate or one of the components cannot be found"
Actually I have an application and in the cab file of that application I have included that exe( in the Program Files folder) and i have tried to put that exe in teh wiindows startup.
Can anyone help me in t his regard as to how tackle this prob
|
|
|
|
|
I think I just answered your question in the MSDN forums. For others looking for the answer you need to change your device security settins so that it will run unsigned executables.
Connect your phone to your computer then in Visual Studio select Tools->Device Security Manager. From there you can change the device's security model to "Security Off"
|
|
|
|
|
@interface testTable2ViewController : UIViewController
{
NSMutableArray **indexStore;
}
@property(nonatomic , retain) NSMutableArray **indexStore;
@end
@implementation testTable2ViewController
@synthesize indexStore;
- (void)viewDidLoad
{
for (NSInteger i = 0; i <10; i++)
{
indexStore[i] = [[NSMutableArray alloc]init];
}//for
}
@end
//////////////////////////////////////////////////////
but indexStore[i] = [[NSMutableArray alloc]init]; can't work
Error Message is EXC_BAD_ACCESS...
why it is not working?hi
My english is a little.
anyway, nice to meet you~~
and give me your advice anytime~
|
|
|
|
|
You never allocate space for indexStore . If you know it'll always have 10 elements, declare it as
NSMutableArray *indexStore[10];
and
@property(nonatomic , retain) NSMutableArray *indexStore[10];
Java, Basic, who cares - it's all a bunch of tree-hugging hippy cr*p
CodeProject MVP for 2010 - who'd'a thunk it!
|
|
|
|
|
Hi, i want to develop a small game for windows mobile with C#.
What is the fastest 2D drawing API? Im very used to XNA, so is there anything that I can use that's similar? I heard GDI is pretty slow.
ThanksStrive to be humble enough to take advice, and confident enough to do something about it.
|
|
|
|
|
If you are drawing sprites then you should use DirectDraw. Unfortunatly DirectDraw isn't directly exposed to .Net developers. But there's another CodeProject article where some one declared all of the imports necessary to begin using DirectDraw from the .Net Compact Framework.
|
|
|
|
|
Hi
I want a thread to start after 15/20 min For that can I use CeRunAppAtTime() .If yes can anyone provide me ways to do that.
Suppose this is my thread
void main()
{
..
..
g_handle= ::CreateThread( NULL, 0,MyThread, NULL, 0, 0);
....
}
Now I want This MyThread to start after 15/20 min can I do that
Thanks in advance
|
|
|
|
|
Start your thread immediatly. When the thread starts have it to create an unnamed event. After creating the event the thread can call CeRunAppAtTime and pass the event handle. Then call the Wait function using the even't handle as athe parameter. The thread will be blocked from running until the event gets triggered.
For information on using CeRunAppAtTime with an event handle please see my comment at the bottom of This MSDN Documentation page[^]
|
|
|
|
|
I am using datagrid in my vb.net (pocket pc) application.
I am using the following code to set the tablestyle to the datagrid to adjust the column width
<pre>
Dim ts As DataGridTableStyle = New DataGridTableStyle
ts.MappingName = "Products"
Dim Product As DataGridTextBoxColumn = New DataGridTextBoxColumn
Product.MappingName = "Product"
Product.HeaderText = "Product"
Product.Width = 130
ts.GridColumnStyles.Add(Product)
Dim Qty As DataGridTextBoxColumn = New DataGridTextBoxColumn
Qty.MappingName = "Quantity"
Qty.HeaderText = "Quantity"
Qty.Width = 75
ts.GridColumnStyles.Add(Qty)
Me.DataGrid1.TableStyles.Add(ts)
Me.DataGrid1.TableStyles(0).GridColumnStyles(0).Width = 100
</pre>
After binding the datagrid I use this code to set the datagridtablestyle but it only show my one column me nothing even it does not return the values in the datagrid with original tablestyle. It show only row header in the grid but does not show the columns.
Any idea how I can solve this problem????
Thanks In advance
|
|
|
|
|
Can anyone suggest a way as to how i can use a timer in a dll.How we can use windows messages or settimer .
Thanks in advance!!!!
|
|
|
|
|
|
SetTimer requires a message pump but my dll doesnt have any. So i cant use it. I need an alternative of Sleep() so that i can use it
|
|
|
|
|
|
Hi
I have a small query. I have a dll and I want it to start as soon as my device reboots. Is there any way of doing it. How about putting it in the windows start up, so that whenever my device will start my dll will also start. Can anyone provide me with some logic.
Thanks in advance!!!!
|
|
|
|
|
You cannot just start a DLL. DLL requires a process to load it. So, may be you can write an application which loads your DLL and calls it's functions. And configure that application to auto-start after booting.
Take a loot at following article:
Automatically Starting Your Application on Windows Mobile[^]
|
|
|
|
|
Hi I have an application in which i have a thread which is expected to do an activity after half hour. SO i used sleep() but while testing(in one scenario) i saw that when the device go in the sleep mode then the time taking to do the activity for that thread is more then the desired time of 30 mins. That is my sleep() is not working accurately when my device goes in the sleep mode. So how can i programatically make a 30 min delay without using any info from the device OS(like gettickcount etc).
My application works fine if I keep the device awake i.e., if i dont allow it to go to the sleep mode forcefully. But the problem arises when it goes to the sleep mode. The time taking is much more ...
Is there any remedy for that.
Thanks in advance!!!
|
|
|
|
|
I just answered this above, but for the sake of some one else that reads this question you shouldn't use Sleep to schedule a thread to run. Instead you must use CeRunAppAtTime. For information on using this function with an event you can see the MSDN documentation page ( here[^]) or you could see the CodeProject.com article I wrote on scheduling a program to automatically start (which is also applicable to threads ig you use the info at the above link) from here[^].
|
|
|
|
|
Hi I am facing some problem in the following code .Actually I am not able to print the full data present in my LPCWSTR .Here is the code
....
SYSTEMTIME current_time;.
GetLocalTime(¤t_time);
char *str =new char[2000];
sprintf(str, "%4d/%2d/%2d %2d:%2d:%2d:%2d\n", current_time.wYear,current_time.wMonth,current_time.wDay,current_time.wHour,current_time.wMinute,current_time.wSecond,current_time.wMilliseconds);
int i;
wchar_t *pwc = (wchar_t *)malloc( sizeof( wchar_t ));
i = mbstowcs( pwc, str, sizeof(str) );
WriteToLogFile(pwc);
delete [] str;
In the log file I just want to print the year date and time but only the year gets printed. Here is the log file
void WriteToLogFile(LPCWSTR strData)
{
try
{
ofstream myfile;
myfile.open("\\MyData\\Log.txt",ios::app);
int iSize = WideCharToMultiByte(CP_ACP,0,strData, -1, NULL, 0, NULL, NULL );
char* lpNarrow = new char[iSize];
lpNarrow[0] = 0;
iSize= WideCharToMultiByte(CP_ACP, 0,strData, -1, lpNarrow, iSize, NULL, NULL );
myfile<<lpNarrow<<endl;
delete [] lpNarrow;
myfile.close();
}
catch(...)
{
}
}
Any help on this..
Thanks in advance
|
|
|
|
|
anuhoho wrote: wchar_t *pwc = (wchar_t *)malloc( sizeof( wchar_t ));
Maybe you should allocate more than 2 bytes for your string. Greetings
Covean
|
|
|
|
|
SO what you suggest seeing the above code,.what should i give
|
|
|
|
|
In addition to my first post this
anuhoho wrote: i = mbstowcs( pwc, str, sizeof(str) );
copies only 4(32bit)/8(64bit) chars to your 2 wchar_t long string, because the call sizeof(str) returns the length of an char* and not the length of the string.Greetings
Covean
|
|
|
|
|