i see but there is no properties like to set background image .
any knows how to do.otherwise have any cotrol tool kits to support windowsmobile
here i m using windows mobile sdk 5.0
Please give me any idea to do this
(or)
How to create custum controls in my window mobile sdk give me idea.
Thanks
Venkat.S
Loading


bina patel10 reputationPosted Jun 21, 2011, 12:20 AM EDT
Venkat S187 reputationPosted Jun 21, 2011, 12:40 AM EDT
thanks for replay.
but i m c# developer and i m not able to understand.
please give any idea.
bina patel10 reputationPosted Jun 21, 2011, 1:05 AM EDT
Add this css in your page and change image path and apply to cssclass of listview control property.
Venkat S187 reputationPosted Jun 21, 2011, 1:22 AM EDT
thanks for replay.
i am new for windows mobile app.
i am using windows mobile sdk to develop device application
it is posible to call css file .
how to call css file in windows mobile forms please give me idea.
bina patel10 reputationPosted Jun 21, 2011, 1:31 AM EDT
Check this link
http://social.msdn.microsoft.com/forums/en-US/netfxcompact/thread/9f04fbca-0730-4182-aedd-993238c0a97b/
Venkat S187 reputationPosted Jun 21, 2011, 1:58 AM EDT
Hi bina patel,
if u dont mind.
let me know how to call this.
i create like this in my form1.cs source code .now how to call background image please give me idea.
(OR)
i m take one class file i put the code then after how can i do.
i ll try two way which is correct.and give me solution please.
static class Helper
{
// ListView messages
private const int LVM_FIRST = 0x1000;
private const int LVM_SETBKIMAGE = (LVM_FIRST + 138);
[Flags]
enum LVBKIF : int
{
SOURCE_NONE = 0x00000000,
SOURCE_HBITMAP = 0x00000001,
SOURCE_URL = 0x00000002,
SOURCE_MASK = 0x00000003,
STYLE_NORMAL = 0x00000000,
STYLE_TILE = 0x00000010,
STYLE_MASK = 0x00000010,
FLAG_TILEOFFSET = 0x00000100
}
class LVBKIMAGE
{
public LVBKIF ulFlags = LVBKIF.SOURCE_NONE;
public IntPtr hbm = IntPtr.Zero;
public IntPtr pszImage = IntPtr.Zero;
public uint cchImageMax = 0;
public int xOffsetPercent = 100;
public int yOffsetPercent = 100;
};
public static void SetBackgroundImage (ListView control, Bitmap bitmap)
{
LVBKIMAGE lvBkImage = new LVBKIMAGE ();
lvBkImage.ulFlags = LVBKIF.SOURCE_HBITMAP | LVBKIF.STYLE_TILE;
lvBkImage.hbm = bitmap.GetHbitmap ();
lvBkImage.cchImageMax = 0;
lvBkImage.xOffsetPercent = 0;
lvBkImage.yOffsetPercent = 0;
Message msg = Message.Create (control.Handle, (int)LVM_SETBKIMAGE, (IntPtr)0, Marshal.AllocCoTaskMem (Marshal.SizeOf (lvBkImage)));
Marshal.StructureToPtr (lvBkImage, msg.LParam, false);
MessageWindow.SendMessage (ref msg);
Marshal.FreeCoTaskMem (msg.LParam);
}
}