Hi Joel, I already tried embedding a simple bmp 5x5 pixels into my exe and still got same problem. I have been digging into it and the problem seems to be that the device I am programming into (HP iPAQ 310) does not have the necessary dll's required by framework. The framework uses gdiplus.dll. Then I believe gdiplus.dll uses gdi32.dll and this dll itself uses coredll.dll. The only one available in this device is coredll.dll and since it's in ROM, I am not able to even place another dll in the windows location. I would have to contact HP to have them provide me a new ROM version that contains this functionality. However, this device has some neat 3D games so the alternative would be to figure out what library those games use. Problem is that I will have to go back to C++ for that. :(
rudy net
Posts
-
Unable to load bitmap with Compact Framework -
Unable to load bitmap with Compact FrameworkHi, I am using CF3.5 on Windows CE5.0 and when I try to create a bitmap using: Bitmp bmp = new Bitmap(filepath) I get the exception error below. I also tried loading file into MemoryStreamm and then tried creating bitmap by passing a memory stream with all bytes corresponding to image but I get same error. I tried loading bmp, jpg, png images but none work. The device I am using is an iPAQ310. Is it possible that it's missing some kind of codec or some driver that compact framework assumes it to be there? If so, what is it missing? Thanks in advance for any help you can provide. System.Exception was unhandled Message="Exception" StackTrace: at Microsoft.AGL.Common.MISC.HandleAr(PAL_ERROR ar) at System.Drawing.Bitmap._InitFromMemoryStream(MemoryStream mstream) at System.Drawing.Bitmap..ctor(String filename) at SkyVision.LocalFileImages.Resources.get_tiny() at SkyVision.FrontViewPanel..ctor() at SkyVision.MainForm.InitializeComponent() at SkyVision.MainForm..ctor() at SkyVision.Program.Main()
-
Need feedback on "Design Pattern Framework 2.0"I just came across this product Design Pattern Framework 2.0. If you have downloaded it or read about it can you give me some feedback on what you think about this product?
-
Is there an equivalent of CWinThread?In C++ I used CWinThread to create forms on separate threads. Is there a CWinThread equivalent for .NET?
-
USB PNPI figured it out by using
ManagementObjectSearcher
class. Wow! This class is really powerful if you ever need to figure out anything from your hardware. Here is the code:string device = "Win32_USBHub"; ManagementObjectSearcher searcher = new ManagementObjectSearcher("Select * from " + device); foreach(ManagementObject mo in searcher.Get()) { Trace.WriteLine(mo.GetPropertyValue("Name")+" "+ mo.GetPropertyValue("PNPDeviceID")); }
Note that there are a ton of hardware classes available from here[^]. Each class has several variables that can be accessed using theGetPropertyValue
method. -
USB PNPHow can I search for a USB PNP ID? For example, when you run "msinfo32.exe" and then expand "Components/USB", it lists all the USB devices as well as their "PNP Device ID". I tried using This Code[^]; however, it doesn't list my USB device, although it does work properly by detecting the mouse and some other devices. One thing I noticed is that all the devices that the code above finds start with "HID" in the msinfo32.exe "PNP Device ID"; however, my device starts with USB. My device id is: USB\VID_0403&PID_6001. -- modified at 20:26 Saturday 13th May, 2006
-
Reflection Problem !First create an instance of your class using
Activator
. Then you should be able to access your structure as usual. Example:Type t = asm.GetType("MyNamespace.MyClass"); MyNamespace.MyClass cls = Activator.CreateInstance(t); cls.StructVar.IntVar = 4;
-
Filtering records in a DataGridHere is an idea you could try: Read the records and store in DataTable "A" Create another DataTable "B" and set your grid's datasource to this table. Launch a thread to copy the records from DataTable A to DataTable B. Use the System.Threading.Thread.Sleep to pause for a few milliseconds every 10 records. Using the Sleep method allows other processes to continue. Hope that helps. Regards, Rudy.
-
DragDrop() Event Handler assistance needed...Try using an offset with respect to the initial position. Modify your alternate code as follows:
ctrl.Left = ctrl.Left + e.X - dragPoint.X; ctrl.Top = ctrl.Top + e.Y - dragPoint.Y;
-
C# equivalent to char * (well, System.IntPtr)??Phil, You can also try using the Marshal static functions. For example:
string s = new string(" ", 2048); IntPtr ptr = Marshal.StringToHGlobalAnsi(s);
Then you can pass ptr to your method. There are other helpful functions available in Marshal that you may be able to use such as:Marshal.AllocHGlobal, or Marshal.PtrToStringAnsi
. Regards, Rudy. -
Source ControlHere are my 2 cents. I used Clearcase at my previous job and when I moved to a new job about a year ago, I learned that they used SourceSafe. After learning how to use SourceSafe and seeing its many disadvantages compared with Clearcase, I decided to look for alternate solutions. I experimented with SourceGear, Surround SCM, QVCS, NGSource, Perforce, and some others that I don't recall. Of all these tools I liked the best Perforce because of its simplicity and a whole great deal of features. What I liked is that it had all of the features available in Clearcase but with a whole great deal of simplicity for for one tenth the price of Clearcase. We have been using it for the last 8 months and everyone just loves it. Our team has 15 people and we have no problems with it at all. Regards, Rudy.
-
That Crystal Reports guy...Thank you so much. I followed your advice and now I don't have to resize my window to avoid seeing that guy.
-
Unable to destroy COM objectI wrote a class in vb.net with the necessary modifications so it can be accessed as COM object from other apps such as VB6. VB6 can access my class and call all methods with no problems. However, when a VB6 user is debugging his/her code and stops his/her running program, the destructor of my COM class doesn't get called (Sub Finalize). My class already has a Dispose method that takes care of all necessary cleanup; however, this method can be called only when VB6 code is running and if user clicks Stop button my class destructor doesn't get called. Please advice because only way to do clean up right now is to completely close VB6 app and restart again.
-
How can I access child controls of a web form? -
How can I access child controls of a web form?Colin, Thanks for your input. You guided me into the right direction. Following is the solution in case anyone needs it as well:
<script language=vbscript> option explicit <!---------------- check/clear text boxes -------------> dim currChkboxName dim currCheckValue sub UpdateCheckboxes(chkboxName, checkValue) currChkboxName = chkboxName currCheckValue = checkValue dim i for i = 0 to Form1.children.length-1 UpdateChildCheckboxes Form1.children(i) next end sub sub UpdateChildCheckboxes(obj) dim i if not obj is nothing then if obj.id <> "" then if InStr(1, obj.id, currChkboxName) > 0 then obj.checked = currCheckValue end if end if for i = 0 to obj.children.length UpdateChildCheckboxes obj.children(i) next end if end sub </script>
Then declare the buttons as follows:<input id="btnClearTestConditions" type=button value="Clear All" onClick="UpdateCheckboxes 'cklTestConditions_', false" /> <input id="btnCheckAllTestConditions" type=button value="Check All" onClick="UpdateCheckboxes 'cklTestConditions_', true" >
-
How can I access child controls of a web form?I am heavily influenced by that as well; however, in this case I would prefer to avoid the trip back to the server.
-
How can I access child controls of a web form?I have a web page with a asp:checklistbox object. I have buttons to "check all" checkboxes; however, to avoid the roundtrip back to the server, I was wondering if I could use jscript to set the checkboxes in the client. The problem I have is how do I access all of the checkboxes that get automatically generated by the checklistbox? If I can access all the checklistboxes of the form then I could set their value to checked.
-
How can I access child controls of a web form?I have a web page with a asp:checklistbox object. I have buttons to "check all" checkboxes; however, to avoid the roundtrip back to the server, I was wondering if I could use jscript to set the checkboxes in the client. The problem I have is how do I access all of the checkboxes that get automatically generated by the checklistbox? If I can access all the checklistboxes of the form then I could set their value to checked.
-
How do I update *.resx files at runtime?My mistake, the subject should say "How do I update *.resx files at design time.
-
How do I update *.resx files at runtime?Humm, I guess I could save the image in a memory stream, then add the image to an ImageList and return the index of the image added so the button can redraw itself. I guess the solution above will work although I am still puzzled if we can make changes to the resx file just like Visual Studio does it at design time. Thanks, Rudy.