use UrlEditor in Component Editor forms

K

Kevin Marshall

Hello everyone,

I have built a server control and managed almost everything I wished to
achieve with it using the book MsPress book on developing server controls, I
do have one problem. I have made a component editor (property builder) form
and its working perfectly apart from my URL properties.

My question:

Is it possible to place a button next to the text fields that can invoke the
UrlEditor dialog and place the result into the text field? or am I going to
have to build my own dialog from scratch to do this, possible inheriting
from the existing dialog is possible.

I have used the UrlEditor successfully in the main property grid but can't
work out how to invoke the dialog from the component editor form.

Thanks in advance for any advice offered.

--
Kevin Marshall
WebXeL.com Ltd
http://www.webxel.com

ASP.NET Dreamweaver Extensions
http://www.webxel-dw.co.uk
 
M

[MSFT]

M

[MSFT]

Hi Kevin,

Did you still have any concerns on this issue? If so, please feel free to
post here.

Luke
 
K

Kevin Marshall

Hi Luke,

Sorry for not getting back to you on this, other thing got in the way (don't
they always).

I am not sure if I am just being dumb or you misunderstood what I wanted to
do, the URL you gave me seem to be instruction on how to wire
editors/designers to the main instance of the property grid that appears
when the control is selected on the design surface, I already have all this
working well, when selecting a URL property the little button appears and
invokes the UrlEditor, example of my OnCancelURL property:

[
Bindable(true),
Category("Cart URLs"),
Browsable(true),
Editor(typeof(UrlEditor),
typeof(UITypeEditor))
]
public string OnCancelURL
{
get{return i_OnCancelURL;}
set{i_OnCancelURL = value;}
}

Like I said, this works fine on the main property grid, my problem is that I
am also using component editor (Property Builder) for the control, so just a
DataGrid control you can right click my control and select "Property
Builder" to open a windows form to allow more convenient editing of the
control properties. the main problem is how can I add a button next to the
text field thats tied to my OnCancelURL property, the button should invoke
the UrlEditor dialog and insert the result into the text field?

It's probably possible but I am a relative beginner at implementing design
time functionality so it seems an impossible task to me at the moment.

Any advice is very much appreciated.

Thank you.

--
Kevin Marshall
WebXeL.com Ltd
http://www.webxel.com

ASP.NET Dreamweaver Extensions
http://www.webxel-dw.co.uk
 
M

[MSFT]

Hi Kevin,

It looks that I misunderstood the question. Did you mean the UrlEditor
Class? It inherits from System.Drawing.Design.UITypeEditor and can only be
used within property grid. We have to create a customized form for other
usage.

Luke
 
K

Kevin Marshall

Ok, I suppose I could make my own using a normal open file dialog, All I
would need to know is how to obtain the physical path of my project file and
the physical path of page currently being worked on.

If I could get both these paths converting the result from the open file
dialog into a URL will be simple enough.

Is that possible?

Thanks

--
Kevin Marshall
WebXeL.com Ltd
http://www.webxel.com

ASP.NET Dreamweaver Extensions
http://www.webxel-dw.co.uk
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top