Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. ASP.NET 2 windows

ASP.NET 2 windows

Scheduled Pinned Locked Moved ASP.NET
questionhelpcsharpasp-net
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Timothy_1982
    wrote on last edited by
    #1

    hi here's my problem i'm developping an asp.net page, i'm a starting asp.net programmer, so don't yet really know much about it, so all help is welcome. I have a page A, and on this page the user has to fill in the name of a picture that's on the webserver. Now what he sees on page a is a textbox (that's disabled and a button choose), if he clicks that button he will get a new window Page B where all the pictures are shown. Now what i would like to know is, how can i when the user clicks a picture on the Page B fill in the name of the picture in the textbox in page A? Or is there a better way to do this? Another question: How can i open a PAGE B as a popupscreen, now when the user clicks the choose button PAGE B is opened in the same windows as PAGE A, i would like to make it possible that page B is opened in a popup window, and than the user selects a foto, and then the name of the foto is saved in the original window. And a last question: is it possible to open a window like the FileOpenDialog in a website, so you can choose a file that's on the webserver!! not the local users computer? I really hope someone can help me with these questions, ALL help is welcome !! thx

    T 1 Reply Last reply
    0
    • T Timothy_1982

      hi here's my problem i'm developping an asp.net page, i'm a starting asp.net programmer, so don't yet really know much about it, so all help is welcome. I have a page A, and on this page the user has to fill in the name of a picture that's on the webserver. Now what he sees on page a is a textbox (that's disabled and a button choose), if he clicks that button he will get a new window Page B where all the pictures are shown. Now what i would like to know is, how can i when the user clicks a picture on the Page B fill in the name of the picture in the textbox in page A? Or is there a better way to do this? Another question: How can i open a PAGE B as a popupscreen, now when the user clicks the choose button PAGE B is opened in the same windows as PAGE A, i would like to make it possible that page B is opened in a popup window, and than the user selects a foto, and then the name of the foto is saved in the original window. And a last question: is it possible to open a window like the FileOpenDialog in a website, so you can choose a file that's on the webserver!! not the local users computer? I really hope someone can help me with these questions, ALL help is welcome !! thx

      T Offline
      T Offline
      tejas_chonkar
      wrote on last edited by
      #2

      Hi Timothy, regarding getting B.aspx as a popup its simple : use window.open() instead of response.redirect("page.aspx"); and for the button on page A.aspx in it's A.aspx.cs file add the following line in the Page load Event ButtonName.Attributes.Add("onclick","callB()"); and add the following script in the html head block as shown. function callB() { window.open("B.aspx","Title",config='height=300,width=650'); } it will open B.aspx in seperate window. :) and regarding to get the picture name in A.aspx page textbox you can use session variable for e.g. use an image button from toolbar use image url to get the picture in it use alternative text to specify the image name (! you can use it later) then on image button click event write the following code Session["picName"] = ImageButton.AlternateText.ToString(); so now the image name is with you in the session variable picName write close event for page B.aspx now in !postback write code to get session variable text in textbox textbox.text = session["picName"].toString(); !remember you need to do error handling when using session else you'll get all those creepy errors on your browser. Some People succeed because they are Destined to, but most people succeed because they are Determined to

      T 1 Reply Last reply
      0
      • T tejas_chonkar

        Hi Timothy, regarding getting B.aspx as a popup its simple : use window.open() instead of response.redirect("page.aspx"); and for the button on page A.aspx in it's A.aspx.cs file add the following line in the Page load Event ButtonName.Attributes.Add("onclick","callB()"); and add the following script in the html head block as shown. function callB() { window.open("B.aspx","Title",config='height=300,width=650'); } it will open B.aspx in seperate window. :) and regarding to get the picture name in A.aspx page textbox you can use session variable for e.g. use an image button from toolbar use image url to get the picture in it use alternative text to specify the image name (! you can use it later) then on image button click event write the following code Session["picName"] = ImageButton.AlternateText.ToString(); so now the image name is with you in the session variable picName write close event for page B.aspx now in !postback write code to get session variable text in textbox textbox.text = session["picName"].toString(); !remember you need to do error handling when using session else you'll get all those creepy errors on your browser. Some People succeed because they are Destined to, but most people succeed because they are Determined to

        T Offline
        T Offline
        Timothy_1982
        wrote on last edited by
        #3

        ok thank you very much for this info, i will try this out this evening thx

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups